Package io.pebbletemplates.pebble.parser
Class ExpressionParser
java.lang.Object
io.pebbletemplates.pebble.parser.ExpressionParser
Parses expressions.
-
Constructor Summary
ConstructorsConstructorDescriptionExpressionParser(Parser parser, Map<String, BinaryOperator> binaryOperators, Map<String, UnaryOperator> unaryOperators, ParserOptions parserOptions) Constructor -
Method Summary
Modifier and TypeMethodDescriptionparseArguments(boolean isMacroDefinition) Expression<?>The public entry point for parsing an expression.Parses a new variable that will need to be initialized in the Java code.
-
Constructor Details
-
ExpressionParser
public ExpressionParser(Parser parser, Map<String, BinaryOperator> binaryOperators, Map<String, UnaryOperator> unaryOperators, ParserOptions parserOptions) Constructor- Parameters:
parser- A reference to the main parserbinaryOperators- All the binary operatorsunaryOperators- All the unary operators
-
-
Method Details
-
parseExpression
The public entry point for parsing an expression.- Returns:
- NodeExpression the expression that has been parsed.
-
parseFilterInvocationExpression
-
parseArguments
-
parseNewVariableName
Parses a new variable that will need to be initialized in the Java code. This is used for the set tag, the for loop, and in named arguments.- Returns:
- A variable name
-