Class NilExpression
- Object
-
- NilExpression
-
- All Implemented Interfaces:
Serializable
,Expression
public final class NilExpression extends Object implements Expression, Serializable
Placeholder class used to represent a NIL expression, evaluates tonull
. This placeholder class allows data structures to avoid the use ofnull
. Please note thatExpression.NIL
is not considered a Literal with valuenull
(since the literal may have its value changed).- Author:
- Jody Garnett (Refractions Research, Inc.), Martin Desruisseaux (Geomatys)
- See Also:
- Serialized Form
-
-
Field Summary
-
Fields inherited from interface Expression
NIL
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Object
accept(ExpressionVisitor visitor, Object extraData)
Accepts a visitor.Object
evaluate(Object object)
Returnsnull
.<T> T
evaluate(Object object, Class<T> context)
Returnsnull
.String
toString()
Returns a string representation of this expression.
-
-
-
Method Detail
-
accept
public Object accept(ExpressionVisitor visitor, Object extraData)
Accepts a visitor.- Specified by:
accept
in interfaceExpression
-
evaluate
public Object evaluate(Object object)
Returnsnull
.- Specified by:
evaluate
in interfaceExpression
- Returns:
- computed value
-
evaluate
public <T> T evaluate(Object object, Class<T> context)
Returnsnull
.- Specified by:
evaluate
in interfaceExpression
- Type Parameters:
T
- The type of the returned object.- Parameters:
object
- The object to evaluate the expression against.context
- The type of the resulting value of the expression.- Returns:
- Evaluates the given expression based on the content of the given object an an
instance of
context
.
-
-