public class FreeMarkerProcessor extends AbstractTemplateProcessor implements TemplateProcessor
Modifier and Type | Field and Description |
---|---|
protected FMContextBuilder |
fmContextBuilder |
protected FreemarkerEngine |
fmEngine |
protected static Pattern |
HtmlTagPattern |
protected freemarker.cache.StringTemplateLoader |
loader |
protected static Pattern |
XMLStartPattern |
BUFFER_SIZE, log
Constructor and Description |
---|
FreeMarkerProcessor() |
Modifier and Type | Method and Description |
---|---|
protected FreemarkerEngine |
getEngine() |
List<TemplateInput> |
getInitialParametersDefinition(Blob blob)
Extract parameters from the Template file.
|
protected String |
guessMimeType(Blob result,
MimetypeRegistry mreg) |
Blob |
renderTemplate(TemplateBasedDocument templateBasedDocument,
String templateName)
Perform rendering of the named template against the
TemplateBasedDocument |
protected void |
setBlobAttributes(Blob result,
TemplateBasedDocument templateBasedDocument) |
getSourceTemplateBlob, getWorkingDir
protected freemarker.cache.StringTemplateLoader loader
protected FreemarkerEngine fmEngine
protected FMContextBuilder fmContextBuilder
protected static final Pattern XMLStartPattern
protected static final Pattern HtmlTagPattern
public FreeMarkerProcessor()
protected FreemarkerEngine getEngine()
protected String guessMimeType(Blob result, MimetypeRegistry mreg)
protected void setBlobAttributes(Blob result, TemplateBasedDocument templateBasedDocument)
public Blob renderTemplate(TemplateBasedDocument templateBasedDocument, String templateName) throws IOException
TemplateProcessor
TemplateBasedDocument
renderTemplate
in interface TemplateProcessor
IOException
public List<TemplateInput> getInitialParametersDefinition(Blob blob) throws IOException
TemplateProcessor
getInitialParametersDefinition
in interface TemplateProcessor
IOException
Copyright © 2016 Nuxeo SA. All rights reserved.