Interface GrammarParser
- All Known Implementing Classes:
LineNumberingShuntingYard
,ShuntingYard
public interface GrammarParser
Interface used by
GrammarMatcher
-
Method Summary
Modifier and TypeMethodDescriptionMain entry point used by the ConfigurableParserCallback function used by GrammarMatchers where the matcher expects a simple number, variable, or function call with optional, prefix or suffix operator.Parse sub expressions.void
Set the iterator used by theparseSubExpression()
-
Method Details
-
parse
Main entry point used by the ConfigurableParser- Parameters:
it
- iterator with the list of tokens- Returns:
- the generated parser tree
- Throws:
ParseException
- if the input cannot be parsed
-
parseSubExpression
Parse sub expressions. This method is used byGrammarMatcher
to parse sub expressions, for instance to parse function arguments.- Returns:
- the root node of the matched sub expression.
- Throws:
ParseException
- if the input cannot be parsed
-
parsePrefixSuffix
Callback function used by GrammarMatchers where the matcher expects a simple number, variable, or function call with optional, prefix or suffix operator.- Returns:
- the root node of the matched sub expression.
- Throws:
ParseException
- if the input cannot be parsed- Since:
- 3.5
-
setIterator
Set the iterator used by theparseSubExpression()
- Parameters:
it
- the iterator- Since:
- 3.4.0
-