Package com.github.mustachejava.codes
Class DefaultMustache
java.lang.Object
com.github.mustachejava.codes.DefaultCode
com.github.mustachejava.codes.DefaultMustache
Default Mustache
-
Field Summary
FieldsFields inherited from class com.github.mustachejava.codes.DefaultCode
appended, binding, df, mustache, name, oh, returnThis, tc, type -
Constructor Summary
ConstructorsConstructorDescriptionDefaultMustache(TemplateContext tc, DefaultMustacheFactory df, Code[] codes, String name) -
Method Summary
Modifier and TypeMethodDescriptionThe default behavior is to run the codes and append the captured text.Code[]getCodes()Get the underlying code objects.voidExecute the mustache to output itself.voidinit()Initialize the mustache before executing.Invert this mustache given output text.booleanOnly executes the codes.voidChange the underlying codes of the mustache implementation.voidMethods inherited from class com.github.mustachejava.codes.DefaultCode
addScope, append, appendText, clone, clone, filterText, get, getName, invert, matchAppended, runIdentity, tag
-
Field Details
-
codes
-
inited
private boolean inited -
isRecursive
private boolean isRecursive
-
-
Constructor Details
-
DefaultMustache
-
-
Method Details
-
getCodes
Description copied from interface:MustacheGet the underlying code objects. -
run
Description copied from interface:MustacheOnly executes the codes. Does not append the text.- Specified by:
runin interfaceMustache- Overrides:
runin classDefaultCode- Parameters:
writer- write the output of the executed template herescopes- the array of scopes to execute- Returns:
- the replacement writer
-
invert
Description copied from interface:MustacheInvert this mustache given output text. -
setCodes
Description copied from interface:MustacheChange the underlying codes of the mustache implementation. -
execute
Description copied from class:DefaultCodeThe default behavior is to run the codes and append the captured text. -
identity
Description copied from interface:MustacheExecute the mustache to output itself. -
init
public void init()Description copied from interface:MustacheInitialize the mustache before executing. This is must be called at least once and is normally called already by the time you have a mustache instance. -
isRecursive
public boolean isRecursive() -
setRecursive
public void setRecursive()
-