org.geotools.filter.visitor
Class DefaultExpressionVisitor
java.lang.Object
org.geotools.filter.visitor.DefaultExpressionVisitor
- All Implemented Interfaces:
- org.opengis.filter.expression.ExpressionVisitor
public abstract class DefaultExpressionVisitor
- extends java.lang.Object
- implements org.opengis.filter.expression.ExpressionVisitor
Abstract implementation of ExpressionVisitor that simply walks the data structure.
This class implements the full ExpressionVisitor interface and will visit every Filter member
of an Expression object. This class performs no actions and is not intended to be used directly,
instead
extend it and overide the methods for the Expression type you are interested in. Remember to call the
super method if you want to ensure that the entire expression tree is still visited.
FilterVisitor allProperties = new DefaultExpressionVisitor(){
public Object visit( PropertyName expr, Object data ) {
Set set = (Set) data;
set.addAll(expr.getPropertyName());
return set;
}
};
Set set = (Set) allProperties.accept(allFids, new HashSet());
- Author:
- Jody
Method Summary |
java.lang.Object |
visit(org.opengis.filter.expression.Add expression,
java.lang.Object data)
|
java.lang.Object |
visit(org.opengis.filter.expression.Divide expression,
java.lang.Object data)
|
java.lang.Object |
visit(org.opengis.filter.expression.Function expression,
java.lang.Object data)
|
java.lang.Object |
visit(org.opengis.filter.expression.Literal expression,
java.lang.Object data)
|
java.lang.Object |
visit(org.opengis.filter.expression.Multiply expression,
java.lang.Object data)
|
java.lang.Object |
visit(org.opengis.filter.expression.NilExpression expression,
java.lang.Object data)
|
java.lang.Object |
visit(org.opengis.filter.expression.PropertyName expression,
java.lang.Object data)
|
java.lang.Object |
visit(org.opengis.filter.expression.Subtract expression,
java.lang.Object data)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
DefaultExpressionVisitor
public DefaultExpressionVisitor()
visit
public java.lang.Object visit(org.opengis.filter.expression.NilExpression expression,
java.lang.Object data)
- Specified by:
visit
in interface org.opengis.filter.expression.ExpressionVisitor
visit
public java.lang.Object visit(org.opengis.filter.expression.Add expression,
java.lang.Object data)
- Specified by:
visit
in interface org.opengis.filter.expression.ExpressionVisitor
visit
public java.lang.Object visit(org.opengis.filter.expression.Divide expression,
java.lang.Object data)
- Specified by:
visit
in interface org.opengis.filter.expression.ExpressionVisitor
visit
public java.lang.Object visit(org.opengis.filter.expression.Function expression,
java.lang.Object data)
- Specified by:
visit
in interface org.opengis.filter.expression.ExpressionVisitor
visit
public java.lang.Object visit(org.opengis.filter.expression.Literal expression,
java.lang.Object data)
- Specified by:
visit
in interface org.opengis.filter.expression.ExpressionVisitor
visit
public java.lang.Object visit(org.opengis.filter.expression.Multiply expression,
java.lang.Object data)
- Specified by:
visit
in interface org.opengis.filter.expression.ExpressionVisitor
visit
public java.lang.Object visit(org.opengis.filter.expression.PropertyName expression,
java.lang.Object data)
- Specified by:
visit
in interface org.opengis.filter.expression.ExpressionVisitor
visit
public java.lang.Object visit(org.opengis.filter.expression.Subtract expression,
java.lang.Object data)
- Specified by:
visit
in interface org.opengis.filter.expression.ExpressionVisitor
Copyright © 1996-2010 Geotools. All Rights Reserved.