Interface TemplateHandler
-
- All Known Implementing Classes:
WikiTemplateHandler
,XhtmlTemplateHandler
public interface TemplateHandler
Processes templates.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description String
generateEditorFormat(PageTemplate template, List<? extends Variable> variables, String spaceKey)
List<Variable>
getTemplateVariables(PageTemplate template)
String
insertVariables(Reader templateXml, List<? extends Variable> variables)
Insert specified variables into the template XML before returning it.
-
-
-
Method Detail
-
getTemplateVariables
List<Variable> getTemplateVariables(PageTemplate template) throws XhtmlException
- Throws:
XhtmlException
-
insertVariables
String insertVariables(Reader templateXml, List<? extends Variable> variables)
Insert specified variables into the template XML before returning it. If an <at:var> is encountered in the XML that doesn't have a value specified, it will be replaced with empty string.- Parameters:
templateXml
- template XMLvariables
- the template variables- Returns:
- the updated template XML with variables replaced with actual values
-
generateEditorFormat
String generateEditorFormat(PageTemplate template, List<? extends Variable> variables, String spaceKey) throws XhtmlException
- Throws:
XhtmlException
-
-