Package org.geotools.filter
Class IsBetweenImpl
- All Implemented Interfaces:
Filter
,MultiValuedFilter
,PropertyIsBetween
,FilterType
Straight implementation of GeoAPI interface.
- Author:
- Justin Deoliveira, The Open Planning Project
-
Nested Class Summary
Nested classes/interfaces inherited from interface MultiValuedFilter
MultiValuedFilter.MatchAction
-
Field Summary
FieldsFields inherited from class BinaryComparisonAbstract
expression1, expression2
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
Fields inherited from interface PropertyIsBetween
NAME
-
Constructor Summary
ConstructorsModifierConstructorDescriptionprotected
IsBetweenImpl
(Expression lower, Expression expression, Expression upper) protected
IsBetweenImpl
(Expression lower, Expression expression, Expression upper, MultiValuedFilter.MatchAction matchAction) -
Method Summary
Modifier and TypeMethodDescriptionaccept
(FilterVisitor visitor, Object extraData) Used by FilterVisitors to perform some action on this filter instance.boolean
Compares this filter to the specified object.boolean
Give an object, this method determines if the test(s) represented by this filter object are passed.boolean
evaluateInternal
(Object value, Object lower, Object upper) Returns the expression to be compared by this operator.Returns the lower bounds (inclusive) an an expression.* Flag Controlling MatchAction property When one or more of the operands evaluates to multiple values rather than a single value, which action should be taken?Returns the upper bounds (inclusive) as an expression.int
hashCode()
Override of hashCode method.void
setExpression
(Expression expression) void
setLowerBoundary
(Expression lowerBoundary) void
setUpperBoundary
(Expression upperBoundary) toString()
Returns a string representation of this filter.Methods inherited from class CompareFilterImpl
compare, setExpression1, setExpression2
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
-
Field Details
-
matchAction
-
-
Constructor Details
-
IsBetweenImpl
protected IsBetweenImpl(Expression lower, Expression expression, Expression upper, MultiValuedFilter.MatchAction matchAction) -
IsBetweenImpl
-
-
Method Details
-
getExpression
Description copied from interface:PropertyIsBetween
Returns the expression to be compared by this operator.- Specified by:
getExpression
in interfacePropertyIsBetween
-
setExpression
-
getMatchAction
Description copied from interface:MultiValuedFilter
* Flag Controlling MatchAction property When one or more of the operands evaluates to multiple values rather than a single value, which action should be taken? If there are n values for the left operand and m values for the right operand, there are n * m possible combinations that can be compared,ANY - if any of the possible combinations match, the result is true (aggregated OR) ALL - only if all of the possible combinations match, the result is true (aggregated AND) ONE - only if exactly one of the possible combinations match, the result is true (aggregated XOR)
- Specified by:
getMatchAction
in interfaceMultiValuedFilter
- Overrides:
getMatchAction
in classBinaryComparisonAbstract
- Returns:
- MatchAction flag
-
evaluate
Description copied from interface:Filter
Give an object, this method determines if the test(s) represented by this filter object are passed.This ability is used to allow Queries against both Features and and non spatial data (such as Record) and to express constraints on permissable data values.
-
evaluateInternal
-
accept
Description copied from class:CompareFilterImpl
Used by FilterVisitors to perform some action on this filter instance. Typicaly used by Filter decoders, but may also be used by any thing which needs infomration from filter structure. Implementations should always call: visitor.visit(this); It is importatant that this is not left to a parent class unless the parents API is identical.- Specified by:
accept
in interfaceFilter
- Specified by:
accept
in classCompareFilterImpl
- Parameters:
visitor
- The visitor which requires access to this filter, the method must call visitor.visit(this);
-
getLowerBoundary
Description copied from interface:PropertyIsBetween
Returns the lower bounds (inclusive) an an expression.- Specified by:
getLowerBoundary
in interfacePropertyIsBetween
-
setLowerBoundary
-
getUpperBoundary
Description copied from interface:PropertyIsBetween
Returns the upper bounds (inclusive) as an expression.- Specified by:
getUpperBoundary
in interfacePropertyIsBetween
-
setUpperBoundary
-
toString
Description copied from class:CompareFilterImpl
Returns a string representation of this filter.- Overrides:
toString
in classCompareFilterImpl
- Returns:
- String representation of the compare filter.
-
hashCode
public int hashCode()Description copied from class:CompareFilterImpl
Override of hashCode method.- Overrides:
hashCode
in classCompareFilterImpl
- Returns:
- a code to hash this object by.
-
equals
Description copied from class:CompareFilterImpl
Compares this filter to the specified object. Returns true if the passed in object is the same as this filter. Checks to make sure the filter types are the same as well as both of the values.- Overrides:
equals
in classCompareFilterImpl
- Parameters:
obj
- - the object to compare this CompareFilter against.- Returns:
- true if specified object is equal to this filter; false otherwise.
-