Interface WoofTemplateExtensionSource
-
- All Known Implementing Classes:
AbstractWoofTemplateExtensionSource
public interface WoofTemplateExtensionSourceSource that allows extending behaviour of aWebTemplate.- Author:
- Daniel Sagenschneider
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description Change<?>createConfigurationChange(WoofTemplateExtensionChangeContext context)This is only invoked by the WoOF editor to enable managing configuration for theWoofTemplateExtensionSource.voidextendTemplate(WoofTemplateExtensionSourceContext context)Extends theWebTemplate.WoofTemplateExtensionSourceSpecificationgetSpecification()Obtains the specification for this.
-
-
-
Method Detail
-
getSpecification
WoofTemplateExtensionSourceSpecification getSpecification()
Obtains the specification for this.
This will be called before any other methods, therefore this method must be able to return the specification immediately after a default constructor instantiation.
- Returns:
- Specification of this.
-
createConfigurationChange
Change<?> createConfigurationChange(WoofTemplateExtensionChangeContext context)
This is only invoked by the WoOF editor to enable managing configuration for the
WoofTemplateExtensionSource. It is not used during extension of theWebTemplate.This method is to create a potential
Changeto the configuration necessary for theWoofTemplateExtensionSource. Should noChangebe required it should returnnull.WoofTemplateExtensionSourceimplementations may require configuration by extra files within the application. This method allows theWoofTemplateExtensionSourceto create/update/delete the files within theConfigurationContext(i.e. Java raw source project).Note that all actions must be undertaken by the returned
Changeas this method may be invoked to validate configuration. This is to avoid side effects by the WoOF editor.Should configuration of the
WoofTemplateExtensionSourcebe invalid, this method should return aChangewith aConflictinstance explaining the reason the configuration is invalid.- Parameters:
context-WoofTemplateExtensionChangeContext.- Returns:
Changeornullif no change is necessary.
-
extendTemplate
void extendTemplate(WoofTemplateExtensionSourceContext context) throws java.lang.Exception
Extends theWebTemplate.- Parameters:
context-WoofTemplateExtensionSourceContext.- Throws:
java.lang.Exception- If fails to extend theWebTemplate.
-
-