|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
public interface Expression
An expression evaluates to a value each time it is evaluated.
If you want to evaluate an expression only once, you better use ExpressionEvaluator.evaluate(String, Mapping).
Parser.parse()| Field Summary | |
|---|---|
static Expression |
FALSE
An expression which always evaluates to false. |
static Expression |
NULL
An expression which always evaluates to null. |
static Expression |
TRUE
An expression which always evaluates to true. |
| Method Summary | |
|---|---|
java.lang.Object |
evaluate(Mapping<java.lang.String,?> variables)
Computes the value of the expression |
java.lang.Object |
evaluateTo(Mapping<java.lang.String,?> variables,
java.lang.Class<?> targetType)
|
boolean |
evaluateToBoolean(Mapping<java.lang.String,?> variables)
|
java.lang.Object |
evaluateToPrimitive(Mapping<java.lang.String,?> variables,
java.lang.Class<?> targetType)
|
| Field Detail |
|---|
static final Expression TRUE
true.
static final Expression FALSE
false.
static final Expression NULL
null.
| Method Detail |
|---|
@Nullable
java.lang.Object evaluate(Mapping<java.lang.String,?> variables)
throws EvaluationException
variables - The values of the variables that were named when the expression was parsed. Allowed
values are String, Integer, Boolean, any other Object, or null.
String, Integer, Boolean, any other Object, or
null
EvaluationException - A problem occurred during evaluation, e.g. a class could not be loaded, or a type
cast could not be performed
@Nullable
java.lang.Object evaluateTo(Mapping<java.lang.String,?> variables,
java.lang.Class<?> targetType)
throws EvaluationException
EvaluationExceptionAbstractExpression.evaluateTo(Mapping, Class)
java.lang.Object evaluateToPrimitive(Mapping<java.lang.String,?> variables,
java.lang.Class<?> targetType)
throws EvaluationException
EvaluationExceptionAbstractExpression.evaluateToPrimitive(Mapping, Class)
boolean evaluateToBoolean(Mapping<java.lang.String,?> variables)
throws EvaluationException
EvaluationExceptionAbstractExpression.evaluateToBoolean(Mapping)
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||