public class Define extends Block
Block.Reference
BLOCK, LINE
Constructor and Description |
---|
Define() |
Modifier and Type | Method and Description |
---|---|
void |
checkArgs(java.util.ArrayList<java.lang.Integer> argtypes,
Token t,
java.lang.String templateName)
Called by the parser to validate the argument types
|
java.lang.String |
getName()
Return name of this directive.
|
void |
init(RuntimeServices rs,
InternalContextAdapter context,
Node node)
simple init - get the key
|
boolean |
render(InternalContextAdapter context,
java.io.Writer writer,
Node node)
directive.render() simply makes an instance of the Block inner class
and places it into the context as indicated.
|
getColumn, getLine, getScopeName, getTemplate, getTemplateName, isScopeProvided, makeScope, postRender, preRender, setLocation, setLocation
public java.lang.String getName()
public void init(RuntimeServices rs, InternalContextAdapter context, Node node) throws TemplateInitException
init
in class Block
TemplateInitException
public boolean render(InternalContextAdapter context, java.io.Writer writer, Node node)
public void checkArgs(java.util.ArrayList<java.lang.Integer> argtypes, Token t, java.lang.String templateName) throws ParseException
checkArgs
in class Directive
argtypes
- type, Array of argument types of each argument to the directive
for example ParserTreeConstants.JJTWORDt
- token of directivetemplateName
- the name of the template this directive is referenced in.ParseException