Package org.stringtemplate.v4
Class STGroupString
- java.lang.Object
-
- org.stringtemplate.v4.STGroup
-
- org.stringtemplate.v4.STGroupString
-
public class STGroupString extends STGroup
A group derived from a string not a file or directory.
-
-
Field Summary
Fields Modifier and Type Field Description protected boolean
alreadyLoaded
String
sourceName
String
text
-
Fields inherited from class org.stringtemplate.v4.STGroup
adaptors, DEFAULT_ERR_MGR, DEFAULT_KEY, defaultGroup, delimiterStartChar, delimiterStopChar, DICT_KEY, dictionaries, encoding, errMgr, GROUP_FILE_EXTENSION, imports, importsToClearOnUnload, iterateAcrossValues, NOT_FOUND_ST, renderers, TEMPLATE_FILE_EXTENSION, templates, trackCreationEvents, verbose
-
-
Constructor Summary
Constructors Constructor Description STGroupString(String text)
STGroupString(String sourceName, String text)
STGroupString(String sourceName, String text, char delimiterStartChar, char delimiterStopChar)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description String
getFileName()
boolean
isDefined(String name)
Is this template defined in this group or from this group below? Names must be absolute, fully-qualified names like/a/b
.boolean
isDictionary(String name)
void
load()
Force a load if it makes sense for the group.protected CompiledST
load(String name)
Load st from disk if directory or load whole group file if .stg file (then return just one template).-
Methods inherited from class org.stringtemplate.v4.STGroup
compile, createSingleton, createStringTemplate, createStringTemplateInternally, createStringTemplateInternally, defineDictionary, defineRegion, defineTemplate, defineTemplate, defineTemplate, defineTemplateAlias, defineTemplateOrRegion, getAttributeRenderer, getEmbeddedInstanceOf, getImportedGroups, getInstanceOf, getListener, getMangledRegionName, getModelAdaptor, getName, getRootDirURL, getTemplateNames, getUnMangledTemplateName, getURL, importTemplates, importTemplates, importTemplates, isReservedCharacter, loadAbsoluteTemplateFile, loadGroupFile, loadTemplateFile, lookupImportedTemplate, lookupTemplate, rawDefineTemplate, rawGetDictionary, rawGetTemplate, registerModelAdaptor, registerRenderer, registerRenderer, setListener, show, toString, undefineTemplate, unload
-
-
-
-
Method Detail
-
isDictionary
public boolean isDictionary(String name)
- Overrides:
isDictionary
in classSTGroup
-
isDefined
public boolean isDefined(String name)
Description copied from class:STGroup
Is this template defined in this group or from this group below? Names must be absolute, fully-qualified names like/a/b
.
-
load
protected CompiledST load(String name)
Description copied from class:STGroup
Load st from disk if directory or load whole group file if .stg file (then return just one template).name
is fully-qualified.
-
load
public void load()
Description copied from class:STGroup
Force a load if it makes sense for the group.
-
getFileName
public String getFileName()
- Overrides:
getFileName
in classSTGroup
-
-