public class GroovyTemplate extends BaseTemplate
Modifier and Type | Class and Description |
---|---|
static class |
GroovyTemplate.ExecutableTemplate
Groovy template
|
static class |
GroovyTemplate.TClassLoader |
BaseTemplate.RawData
compiledSource, compiledTemplate, compiledTemplateName, currentTemplate, doBodyLines, layout, layoutData, linesMatrix, timestamp
Constructor and Description |
---|
GroovyTemplate(java.lang.String source) |
GroovyTemplate(java.lang.String name,
java.lang.String source) |
Modifier and Type | Method and Description |
---|---|
protected java.lang.Throwable |
cleanStackTrace(java.lang.Throwable e) |
void |
compile() |
protected java.lang.String |
internalRender(java.util.Map<java.lang.String,java.lang.Object> args)
The internal rendering method - When one template calls another template, this method is used.
|
protected static boolean |
isSimpleParam(java.lang.Class type) |
protected void |
onCompileEnd() |
static <T> void |
registerFormatter(java.lang.String format,
SafeFormatter formatter) |
java.lang.String |
render(java.util.Map<java.lang.String,java.lang.Object> args)
Starts the rendering process without modifying the args-map
|
protected groovy.lang.Binding |
setUpBindingVariables(java.util.Map<java.lang.String,java.lang.Object> args) |
protected org.codehaus.groovy.control.CompilerConfiguration |
setUpCompilerConfiguration() |
loadFromCache, loadPrecompiled
public GroovyTemplate(java.lang.String name, java.lang.String source)
public GroovyTemplate(java.lang.String source)
public static <T> void registerFormatter(java.lang.String format, SafeFormatter formatter)
protected org.codehaus.groovy.control.CompilerConfiguration setUpCompilerConfiguration()
protected void onCompileEnd()
public java.lang.String render(java.util.Map<java.lang.String,java.lang.Object> args)
Template
protected groovy.lang.Binding setUpBindingVariables(java.util.Map<java.lang.String,java.lang.Object> args)
protected java.lang.String internalRender(java.util.Map<java.lang.String,java.lang.Object> args)
Template
internalRender
in class Template
args
- List of arguments use in renderprotected java.lang.Throwable cleanStackTrace(java.lang.Throwable e)
cleanStackTrace
in class BaseTemplate
protected static boolean isSimpleParam(java.lang.Class type)
Guillaume Bort & zenexity - Distributed under Apache 2 licence, without any warrantly