Class InterpretingELExpressionParser
java.lang.Object
io.micronaut.el.interpreter.InterpretingELExpressionParser
- All Implemented Interfaces:
ELExpressionParser
@Internal
public final class InterpretingELExpressionParser
extends Object
implements ELExpressionParser
Creates the expressions that were not compiled at compilation time by parsing them at runtime.
The implementation is registered as a service, so adding this module to the runtime classpath is enough
to make jakarta.el.ExpressionFactory accept expression strings that are only known at runtime.
- Since:
- 1.0
- Author:
- Denis Stepanov
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionjakarta.el.MethodExpressioncreateMethodExpression(@Nullable jakarta.el.ELContext context, String expression, Class<?> expectedReturnType, Class<?>[] expectedParamTypes) Parses a method expression.jakarta.el.ValueExpressioncreateValueExpression(@Nullable jakarta.el.ELContext context, String expression, Class<?> expectedType) Parses a value expression.
-
Constructor Details
-
InterpretingELExpressionParser
public InterpretingELExpressionParser()
-
-
Method Details
-
createValueExpression
public jakarta.el.ValueExpression createValueExpression(@Nullable jakarta.el.ELContext context, String expression, Class<?> expectedType) Description copied from interface:ELExpressionParserParses a value expression.- Specified by:
createValueExpressionin interfaceELExpressionParser- Parameters:
context- The context the expression is created for, can benullexpression- The expressionexpectedType- The expected type of the evaluation result- Returns:
- The value expression
-
createMethodExpression
public jakarta.el.MethodExpression createMethodExpression(@Nullable jakarta.el.ELContext context, String expression, Class<?> expectedReturnType, Class<?>[] expectedParamTypes) Description copied from interface:ELExpressionParserParses a method expression.- Specified by:
createMethodExpressionin interfaceELExpressionParser- Parameters:
context- The context the expression is created for, can benullexpression- The expressionexpectedReturnType- The expected return typeexpectedParamTypes- The expected parameter types- Returns:
- The method expression
-