| java.lang.Object org.geotools.filter.expression.ExpressionAbstract org.geotools.filter.DefaultExpression
All known Subclasses: org.geotools.filter.MathExpressionImpl, org.geotools.filter.LiteralExpressionImpl, org.geotools.filter.FunctionExpressionImpl, org.geotools.filter.AttributeExpressionImpl2, org.geotools.filter.MapScaleDenominatorImpl, org.geotools.filter.GeometryExpressionImpl, org.geotools.filter.function.ClassificationFunction, org.geotools.filter.AttributeExpressionImpl,
DefaultExpression | abstract public class DefaultExpression extends ExpressionAbstract implements Expression(Code) | | Implements a default expression, with helpful variables and static methods.
author: Rob Hranac, Vision for New York version: $Id: DefaultExpression.java 24280 2007-02-08 16:40:54Z groldan $ |
Method Summary | |
final public void | accept(FilterVisitor visitor) | public Object | evaluate(Feature feature) Returns a value for this expression. | public Object | evaluate(Object object) This method checks if the object is an instance of
Feature and
if so, calls through to
DefaultExpression.evaluate(Feature) . | public short | getType() Gets the type of this expression. | final public Object | getValue(Feature feature) This method calls
DefaultExpression.evaluate(Feature) . | protected static boolean | isAttributeExpression(short expressionType) Checks to see if passed type is attribute.
Parameters: expressionType - Type of expression for check. | protected static boolean | isExpression(short expressionType) Checks to see if passed type is geometry.
Parameters: expressionType - Type of expression for check. | public static boolean | isFunctionExpression(short expressionType) | protected static boolean | isGeometryExpression(short expressionType) Checks to see if passed type is geometry.
Parameters: expressionType - Type of expression for check. | protected static boolean | isLiteralExpression(short expressionType) Checks to see if passed type is geometry.
Parameters: expressionType - Type of expression for check. | protected static boolean | isMathExpression(short expressionType) Checks to see if passed type is math.
Parameters: expressionType - Type of expression for check. | protected static boolean | isMathExpression(org.opengis.filter.expression.Expression expression) Checks to see if this expression is a math expresson based on its type.
Parameters: expression - expression to check. |
expressionType | protected short expressionType(Code) | | Defines the type of this expression.
|
permissiveConstruction | protected boolean permissiveConstruction(Code) | | Defines the type of this expression.
|
accept | final public void accept(FilterVisitor visitor)(Code) | | org.opengis.filter.expression.Expression.accept(ExpressionVisitorObject) |
evaluate | public Object evaluate(Feature feature)(Code) | | Returns a value for this expression. If the expression is an attribute
expression then the attribute of the feature should be returned. If a
literal then the feature is ignored, the literal is returned as it has
no relation to the feature.
Parameters: feature - Specified feature to use when returning value. The value of this expression based on the feature. |
evaluate | public Object evaluate(Object object)(Code) | | This method checks if the object is an instance of
Feature and
if so, calls through to
DefaultExpression.evaluate(Feature) . This is done
to maintain backwards compatability with previous version of Expression api
which depended on Feature. If the object is not an instance of feature
the super implementation is called.
|
getType | public short getType()(Code) | | Gets the type of this expression.
The short representation of the expression type. |
isAttributeExpression | protected static boolean isAttributeExpression(short expressionType)(Code) | | Checks to see if passed type is attribute.
Parameters: expressionType - Type of expression for check. Whether or not this is an attribute expression type. |
isExpression | protected static boolean isExpression(short expressionType)(Code) | | Checks to see if passed type is geometry.
Parameters: expressionType - Type of expression for check. Whether or not this is a geometry expression type. |
isFunctionExpression | public static boolean isFunctionExpression(short expressionType)(Code) | | |
isGeometryExpression | protected static boolean isGeometryExpression(short expressionType)(Code) | | Checks to see if passed type is geometry.
Parameters: expressionType - Type of expression for check. Whether or not this is a geometry expression type. |
isLiteralExpression | protected static boolean isLiteralExpression(short expressionType)(Code) | | Checks to see if passed type is geometry.
Parameters: expressionType - Type of expression for check. Whether or not this is a geometry expression type. |
isMathExpression | protected static boolean isMathExpression(short expressionType)(Code) | | Checks to see if passed type is math.
Parameters: expressionType - Type of expression for check. Whether or not this is a math expression type.DefaultExpression.is |
isMathExpression | protected static boolean isMathExpression(org.opengis.filter.expression.Expression expression)(Code) | | Checks to see if this expression is a math expresson based on its type.
Parameters: expression - expression to check. Whether or not this is a math expression. |
|
|