Package org.geotools.filter.spatial
Class WithinImpl
-
- All Implemented Interfaces:
Filter
,MultiValuedFilter
,BinarySpatialOperator
,BoundedSpatialOperator
,SpatialOperator
,Within
,FilterType
public class WithinImpl extends AbstractPreparedGeometryFilter implements Within
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class AbstractPreparedGeometryFilter
AbstractPreparedGeometryFilter.Literals
-
Nested classes/interfaces inherited from interface MultiValuedFilter
MultiValuedFilter.MatchAction
-
-
Field Summary
-
Fields inherited from class AbstractPreparedGeometryFilter
cacheValue, leftPreppedGeom, literals, rightPreppedGeom
-
Fields inherited from class GeometryFilterImpl
matchAction
-
Fields inherited from class BinaryComparisonAbstract
expression1, expression2
-
Fields inherited from class AbstractFilter
LOGGER
-
Fields inherited from interface FilterType
ALL, BETWEEN, COMPARE_EQUALS, COMPARE_GREATER_THAN, COMPARE_GREATER_THAN_EQUAL, COMPARE_LESS_THAN, COMPARE_LESS_THAN_EQUAL, COMPARE_NOT_EQUALS, FID, GEOMETRY_BBOX, GEOMETRY_BEYOND, GEOMETRY_CONTAINS, GEOMETRY_CROSSES, GEOMETRY_DISJOINT, GEOMETRY_DWITHIN, GEOMETRY_EQUALS, GEOMETRY_INTERSECTS, GEOMETRY_OVERLAPS, GEOMETRY_TOUCHES, GEOMETRY_WITHIN, LIKE, LOGIC_AND, LOGIC_NOT, LOGIC_OR, NONE, NULL
-
-
Constructor Summary
Constructors Constructor Description WithinImpl(Expression e1, Expression e2)
WithinImpl(Expression e1, Expression e2, MultiValuedFilter.MatchAction matchAction)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Object
accept(FilterVisitor visitor, Object extraData)
Accepts a visitor.protected boolean
basicEvaluate(Geometry left, Geometry right)
Performs the calculation on the two geometries.boolean
evaluateInternal(Geometry left, Geometry right)
Performs the calculation on the two geometries.-
Methods inherited from class AbstractPreparedGeometryFilter
setExpression1, setExpression2
-
Methods inherited from class GeometryFilterImpl
equals, evaluate, getGeometries, getMatchAction, hashCode, toString
-
Methods inherited from class BinaryComparisonAbstract
comparable, eval, eval, getExpression1, getExpression2, isMatchingCase
-
Methods inherited from class AbstractFilter
isCompareFilter, isGeometryDistanceFilter, isGeometryFilter, isLogicFilter, isMathFilter, isSimpleFilter
-
Methods inherited from class FilterAbstract
accepts, eval, eval
-
Methods inherited from interface BinarySpatialOperator
getExpression1, getExpression2
-
Methods inherited from interface MultiValuedFilter
getMatchAction
-
-
-
-
Constructor Detail
-
WithinImpl
public WithinImpl(Expression e1, Expression e2)
-
WithinImpl
public WithinImpl(Expression e1, Expression e2, MultiValuedFilter.MatchAction matchAction)
-
-
Method Detail
-
evaluateInternal
public boolean evaluateInternal(Geometry left, Geometry right)
Description copied from class:GeometryFilterImpl
Performs the calculation on the two geometries.- Specified by:
evaluateInternal
in classGeometryFilterImpl
- Parameters:
left
- the geometry on the left of the equations (the geometry obtained from evaluating Expression1)right
- the geometry on the right of the equations (the geometry obtained from evaluating Expression2)- Returns:
- true if the filter evaluates to true for the two geometries
-
accept
public Object accept(FilterVisitor visitor, Object extraData)
Description copied from interface:Filter
Accepts a visitor.Implementations of all subinterfaces must have with a method whose content is the following:
return visitor.visit(this, extraData);
-
basicEvaluate
protected boolean basicEvaluate(Geometry left, Geometry right)
Description copied from class:AbstractPreparedGeometryFilter
Performs the calculation on the two geometries. This is used to calculate the cached value in the case that both geometries are Literals. But in practice it is useful to extract this functionality into its own method.- Specified by:
basicEvaluate
in classAbstractPreparedGeometryFilter
- Parameters:
left
- the geometry on the left of the equations (the geometry obtained from evaluating Expression1)right
- the geometry on the right of the equations (the geometry obtained from evaluating Expression2)- Returns:
- true if the filter evaluates to true for the two geometries
-
-