public class FunctionGrammarMatcher extends java.lang.Object implements GrammarMatcher
Constructor and Description |
---|
FunctionGrammarMatcher(Token open,
Token close,
Token comma)
Create a FunctionGrammarMatcher
|
Modifier and Type | Method and Description |
---|---|
protected Token |
errorToken(Lookahead2Iterator<Token> it)
Generate a token to use in GrammarExecptions
|
void |
init(Jep jep)
Delayed initialisation, this methods is called whenever components of the jep instance are changed.
|
Node |
match(Lookahead2Iterator<Token> it,
GrammarParser parser)
Attempt to match a function, calls the GrammarParser.parseSubExpression()
to match function arguments.
|
public void init(Jep jep)
GrammarMatcher
init
in interface GrammarMatcher
jep
- the current jep instance.protected Token errorToken(Lookahead2Iterator<Token> it)
it
- used to get current positionpublic Node match(Lookahead2Iterator<Token> it, GrammarParser parser) throws ParseException
match
in interface GrammarMatcher
it
- An iterator inspecting the inputparser
- the parser to use when evaluating sub expressionsParseException
- if there is a syntactical error in the input.Copyright © 2018 Singular Systems http://www.singularsys.com/jep