Constructor and Description |
---|
ParseErrorException(ParseException pex,
String templName)
Create a ParseErrorException with the given ParseException.
|
TemplateInitException(String msg,
ParseException parseException,
String templateName,
int col,
int line) |
Modifier and Type | Method and Description |
---|---|
static SimpleNode |
RuntimeSingleton.parse(Reader reader,
Template template)
Parse the input and return the root of
AST node structure.
|
SimpleNode |
RuntimeServices.parse(Reader reader,
Template template)
Parse the input and return the root of
AST node structure.
|
SimpleNode |
RuntimeInstance.parse(Reader reader,
Template template)
Parse the input and return the root of
AST node structure.
|
Modifier and Type | Class and Description |
---|---|
class |
MacroParseException
Exception to indicate problem happened while constructing #macro()
For internal use in parser - not to be passed to app level
|
Modifier and Type | Method and Description |
---|---|
void |
Directive.checkArgs(ArrayList<Integer> argtypes,
Token t,
String templateName)
The Parser calls this method during template parsing to check the arguments
types.
|
void |
Break.checkArgs(ArrayList<Integer> argtypes,
Token t,
String templateName)
Called by the parser to validate the argument types
|
void |
Macro.checkArgs(ArrayList<Integer> argtypes,
Token t,
String templateName)
Check the argument types of a macro call, called by the parser to do validation
|
void |
Stop.checkArgs(ArrayList<Integer> argtypes,
Token t,
String templateName)
Called by the parser to check the argument types
|
void |
Parse.checkArgs(ArrayList<Integer> argtypes,
Token t,
String templateName)
Called by the parser to validate the argument types
|
void |
Foreach.checkArgs(ArrayList<Integer> argtypes,
Token t,
String templateName)
We do not allow a word token in any other arg position except for the 2nd since
we are looking for the pattern #foreach($foo in $bar).
|
void |
Define.checkArgs(ArrayList<Integer> argtypes,
Token t,
String templateName)
Called by the parser to validate the argument types
|
Modifier and Type | Method and Description |
---|---|
void |
For.checkArgs(ArrayList<Integer> argtypes,
Token t,
String templateName)
We do not allow a word token in any other arg position except for the 2nd
since we are looking for the pattern #foreach($foo in $bar).
|
Modifier and Type | Class and Description |
---|---|
class |
TemplateParseException
This is an extension of the ParseException, which also takes a
template name.
|
Modifier and Type | Method and Description |
---|---|
ParseException |
Parser.generateParseException()
Generate ParseException.
|
Modifier and Type | Method and Description |
---|---|
void |
Parser.AdditiveExpression() |
void |
Parser.Assignment() |
void |
Parser.Comment() |
void |
Parser.ConditionalAndExpression() |
void |
Parser.ConditionalOrExpression() |
boolean |
Parser.Directive()
Supports the Pluggable Directives
#foo( arg+ )
|
int |
Parser.DirectiveArg()
Supports the arguments for the Pluggable Directives
|
void |
Parser.DirectiveAssign() |
ASTBlock |
Parser.ElseIfStatement(ASTBlock previousBlock) |
ASTBlock |
Parser.ElseStatement(ASTBlock previousBlock) |
void |
Parser.EqualityExpression() |
void |
Parser.Escape()
Used to catch and process escape sequences in grammatical constructs
as escapes outside of VTL are just characters.
|
void |
Parser.EscapedDirective()
used to separate the notion of a valid directive that has been
escaped, versus something that looks like a directive and
is just schmoo.
|
void |
Parser.Expression() |
void |
Parser.False() |
void |
Parser.FloatingPointLiteral() |
void |
Parser.Identifier()
This method corresponds to variable
references in Velocity templates.
|
boolean |
Parser.IfStatement() |
void |
Parser.Index() |
void |
Parser.IndexParameter()
A Simplified parameter more suitable for an index position: $foo[$index]
|
void |
Parser.IntegerLiteral() |
void |
Parser.IntegerRange()
supports the [n..m] vector generator for use in
the #foreach() to generate measured ranges w/o
needing explicit support from the app/servlet
|
void |
Parser.Map()
for creating a map in a #set
#set($foo = {$foo : $bar, $blargh : $thingy})
|
void |
Parser.Method()
This method has yet to be fully implemented
but will allow arbitrarily nested method
calls
|
void |
Parser.MultiplicativeExpression() |
void |
Parser.ObjectArray() |
void |
Parser.Parameter()
This method has yet to be fully implemented
but will allow arbitrarily nested method
calls
|
SimpleNode |
Parser.parse(Reader reader,
Template template)
This was also added to allow parsers to be
re-usable.
|
void |
Parser.PrimaryExpression() |
SimpleNode |
Parser.process()
This method is what starts the whole parsing
process.
|
void |
Parser.Reference() |
void |
Parser.RelationalExpression() |
boolean |
Parser.SetDirective()
Currently support both types of set :
#set( expr )
#set expr
|
boolean |
Parser.Statement(boolean afterNewline)
These are the types of statements that
are acceptable in Velocity templates.
|
void |
Parser.StringLiteral() |
boolean |
Parser.Text()
This method is responsible for allowing
all non-grammar text to pass through
unscathed.
|
void |
Parser.Textblock() |
void |
Parser.True() |
void |
Parser.UnaryExpression() |
void |
Parser.Word() |
Copyright © 2000–2017 The Apache Software Foundation. All rights reserved.