Name
ExpressionEvaluator
Synopsis
The
ExpressionEvaluator
is the main class for the EL machinery,
providing methods for preparation and evaluation of a single EL
expression. In a JSP environment, an instance of this class can be
obtained from the JspContext
.
Synopsis
Class name: |
javax.servlet.jsp.el.ExpressionEvaluator |
Extends: |
None |
Implements: |
None |
Implemented by: |
Internal container-dependent class; most containers use the reference implementation of the class (developed in the Apache Jakarta project) |
Constructors
-
public ExpressionEvaluator( )
Creates a new
ExpressionEvaluator
instance.
Methods
-
public abstract Object evaluate(String expression, Class expectedType, VariableResolver variableResolver, FunctionMapper functionMapper) throws ELException
Evaluates the expression (a String starting with
${
and ending with}
) using the variables provided by theVariableResolver
and the functions provided by theFunctionMapper
. The evaluation result is coerced to the specified expected type according to the rules described in Appendix C and returned.-
public abstract Object parseExpression(String expression, Class expectedType, FunctionMapper functionMapper) throws ELException
Prepares the expression (a String starting with
${
and ending with}
) for later evaluation. The method typically performs syntactic validation and throws anELParseException
if an error is found.
Get JavaServer Pages, 3rd Edition now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.