Class FilterDelegate<T>
- Type Parameters:
T- Generic type that the FilterDelegate will return as a final result
FilterAdapter. The FilterAdapter will
visit a Filter and call the corresponding delegate methods after
type conversion and input normalization.
Not all org.geotools.api.filter.Filter and Expression types are supported by the delegate. FilterAdapter
and FilterDelegate would need to be extended to support other org.geotools.api.filter.Filter and
org.geotools.api.filter.expression.Expression types. Alternatively, other types could be
supported by implementing the FilterVisitor directly.
A reference implementation is provided with the DDF Core in the org.geotools.api.filter.Filter Proxy bundle.
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final StringNormalized escape character used to escape the meaning of the wildCard, singleChar, and the escapeChar itselfstatic final StringNormalized single wildcard character used to match exactly one characterstatic final StringNormalized wildcard character used to match zero or more characters. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionCompares the value associated with a property is after a givenDate.Logical "and" operation on a list of operands.Compares the value associated with a property is before a givenDate.This is an exclusive comparison.Compares the value associated with the property by checking if it is start at the start date and ends some time before the endDateCompares the geometry associated with a property is beyond a distance from a WKT geometry.Compares the geometry associated with a property is contained by a WKT geometry.Compares the geometry associated with a property crosses a WKT geometry.Compares the geometry associated with a property is disjoint from a WKT geometry.Compares the value associated with a property is between a start and end date.Compares the geometry associated with a property is within a distance from a WKT geometry.exclude()Include filter is equivalent to filter all or logicallyfalse.include()Include filter is equivalent to no filtering or logicallytrue.intersects(String propertyName, String wkt) Compares the geometry associated with a property intersects a WKT geometry.nearestNeighbor(String propertyName, String wkt) Returns a sorted list of the nearest neighbors to a property for a given WKT.Logical "not" operation on an operand.Logical "or" operation on a list of operands.Compares the geometry associated with a property overlaps a WKT geometry.propertyIsBetween(String propertyName, double lowerBoundary, double upperBoundary) propertyIsBetween(String propertyName, float lowerBoundary, float upperBoundary) propertyIsBetween(String propertyName, int lowerBoundary, int upperBoundary) propertyIsBetween(String propertyName, long lowerBoundary, long upperBoundary) propertyIsBetween(String propertyName, short lowerBoundary, short upperBoundary) propertyIsBetween(String propertyName, Object lowerBoundary, Object upperBoundary) Compares the value associated with a property is between a lower and upper boundary.propertyIsBetween(String propertyName, String lowerBoundary, String upperBoundary) propertyIsBetween(String propertyName, Date lowerBoundary, Date upperBoundary) propertyIsEqualTo(String propertyName, boolean literal) propertyIsEqualTo(String propertyName, byte[] literal) propertyIsEqualTo(String propertyName, double literal) propertyIsEqualTo(String propertyName, float literal) propertyIsEqualTo(String propertyName, int literal) propertyIsEqualTo(String propertyName, long literal) propertyIsEqualTo(String propertyName, short literal) propertyIsEqualTo(String propertyName, Object literal) Compares the value associated with a property is equal to the value of a literal.propertyIsEqualTo(String propertyName, String literal, boolean isCaseSensitive) propertyIsEqualTo(String propertyName, Date literal) propertyIsEqualTo(String propertyName, Date startDate, Date endDate) propertyIsEqualTo(String functionName, List<Object> arguments, Object literal) Compares the function return value is equal to the value of a literal.propertyIsFuzzy(String propertyName, String literal) Compares the value associated with a property to the value of a literal with a fuzzy operator which expands the literal to match misspellings.propertyIsGreaterThan(String propertyName, double literal) propertyIsGreaterThan(String propertyName, float literal) propertyIsGreaterThan(String propertyName, int literal) propertyIsGreaterThan(String propertyName, long literal) propertyIsGreaterThan(String propertyName, short literal) propertyIsGreaterThan(String propertyName, Object literal) Compares the value associated with a property is greater than the value of a literal.propertyIsGreaterThan(String propertyName, String literal) propertyIsGreaterThan(String propertyName, Date literal) propertyIsGreaterThanOrEqualTo(String propertyName, double literal) propertyIsGreaterThanOrEqualTo(String propertyName, float literal) propertyIsGreaterThanOrEqualTo(String propertyName, int literal) propertyIsGreaterThanOrEqualTo(String propertyName, long literal) propertyIsGreaterThanOrEqualTo(String propertyName, short literal) propertyIsGreaterThanOrEqualTo(String propertyName, Object literal) Compares the value associated with a property is greater than or equal to the value of a literal.propertyIsGreaterThanOrEqualTo(String propertyName, String literal) propertyIsGreaterThanOrEqualTo(String propertyName, Date literal) propertyIsLessThan(String propertyName, double literal) propertyIsLessThan(String propertyName, float literal) propertyIsLessThan(String propertyName, int literal) propertyIsLessThan(String propertyName, long literal) propertyIsLessThan(String propertyName, short literal) propertyIsLessThan(String propertyName, Object literal) Compares the value associated with a property is less than the value of a literal.propertyIsLessThan(String propertyName, String literal) propertyIsLessThan(String propertyName, Date literal) propertyIsLessThanOrEqualTo(String propertyName, double literal) propertyIsLessThanOrEqualTo(String propertyName, float literal) propertyIsLessThanOrEqualTo(String propertyName, int literal) propertyIsLessThanOrEqualTo(String propertyName, long literal) propertyIsLessThanOrEqualTo(String propertyName, short literal) propertyIsLessThanOrEqualTo(String propertyName, Object literal) Compares the value associated with a property is less than or equal to the value of a literal.propertyIsLessThanOrEqualTo(String propertyName, String literal) propertyIsLessThanOrEqualTo(String propertyName, Date literal) propertyIsLike(String propertyName, String pattern, boolean isCaseSensitive) Compares the value associated with a property to a regular expression pattern.propertyIsNotEqualTo(String propertyName, boolean literal) propertyIsNotEqualTo(String propertyName, byte[] literal) propertyIsNotEqualTo(String propertyName, double literal) propertyIsNotEqualTo(String propertyName, float literal) propertyIsNotEqualTo(String propertyName, int literal) propertyIsNotEqualTo(String propertyName, long literal) propertyIsNotEqualTo(String propertyName, short literal) propertyIsNotEqualTo(String propertyName, Object literal) Compares the value associated with a property is not equal to the value of a literal.propertyIsNotEqualTo(String propertyName, String literal, boolean isCaseSensitive) propertyIsNotEqualTo(String propertyName, Date literal) propertyIsNotEqualTo(String propertyName, Date startDate, Date endDate) propertyIsNull(String propertyName) Compares the value associated with a property is equal tonull.Compares the value associated with a property is relatively within a duration of milliseconds in the past from the current time of evaluation.Compares the geometry associated with a property touches a WKT geometry.Compares the geometry associated with a property is within a WKT geometry.xpathExists(String xpath) Deprecated.xpathIsFuzzy(String xpath, String literal) Deprecated.xpathIsLike(String xpath, String pattern, boolean isCaseSensitive) Deprecated.
-
Field Details
-
WILDCARD_CHAR
Normalized wildcard character used to match zero or more characters.- See Also:
-
SINGLE_CHAR
Normalized single wildcard character used to match exactly one character- See Also:
-
ESCAPE_CHAR
Normalized escape character used to escape the meaning of the wildCard, singleChar, and the escapeChar itself- See Also:
-
-
Constructor Details
-
FilterDelegate
public FilterDelegate()
-
-
Method Details
-
and
Logical "and" operation on a list of operands.- Parameters:
operands- list of operands to "and"- Returns:
- result of "and" operation on operands
-
or
Logical "or" operation on a list of operands.- Parameters:
operands- list of T to "or"- Returns:
- result of "or" operation on operands
-
nearestNeighbor
Returns a sorted list of the nearest neighbors to a property for a given WKT.- Parameters:
propertyName- name of property to comparewkt- WKT geometry to compare- Returns:
- result of nearest neighbor spatial operation
-
not
Logical "not" operation on an operand.- Parameters:
operand- operand to negate- Returns:
- result of "not" operation on operand
-
include
Include filter is equivalent to no filtering or logicallytrue.- Returns:
- returns the equivalent of true
-
exclude
Include filter is equivalent to filter all or logicallyfalse.- Returns:
- returns the equivalent of false
-
propertyIsEqualTo
- Parameters:
propertyName- name of property to compareliteral- value to compareisCaseSensitive- case-sensitivity boolean- Returns:
- result of equals operation between
propertyNameandliteral - See Also:
-
propertyIsEqualTo
- Parameters:
propertyName- name of property to compareliteral- value to compare- Returns:
- result of equals operation between
propertyNameandliteral - See Also:
-
propertyIsEqualTo
- Parameters:
propertyName- name of property to comparestartDate- starting date of literal to compareendDate- ending date of literal to compare- Returns:
- result of equals operation between
propertyNameandliteral - See Also:
-
propertyIsEqualTo
- Parameters:
propertyName- name of property to compareliteral- value to compare- Returns:
- result of equals operation between
propertyNameandliteral - See Also:
-
propertyIsEqualTo
- Parameters:
propertyName- name of property to compareliteral- value to compare- Returns:
- result of equals operation between
propertyNameandliteral - See Also:
-
propertyIsEqualTo
- Parameters:
propertyName- name of property to compareliteral- value to compare- Returns:
- result of equals operation between
propertyNameandliteral - See Also:
-
propertyIsEqualTo
- Parameters:
propertyName- name of property to compareliteral- value to compare- Returns:
- result of equals operation between
propertyNameandliteral - See Also:
-
propertyIsEqualTo
- Parameters:
propertyName- name of property to compareliteral- value to compare- Returns:
- result of equals operation between
propertyNameandliteral - See Also:
-
propertyIsEqualTo
- Parameters:
propertyName- name of property to compareliteral- value to compare- Returns:
- result of equals operation between
propertyNameandliteral - See Also:
-
propertyIsEqualTo
- Parameters:
propertyName- name of property to compareliteral- value to compare- Returns:
- result of equals operation between
propertyNameandliteral - See Also:
-
propertyIsEqualTo
Compares the value associated with a property is equal to the value of a literal.propertyName == literal- Parameters:
propertyName- name of property to compareliteral- value to compare- Returns:
- result of equals operation between
propertyNameandliteral
-
propertyIsEqualTo
Compares the function return value is equal to the value of a literal. Filter delegates will have to know the function argument types and return types for each specific function in order to support it, therefore to simplify the API they are just passed as objects.function result == literal- Parameters:
functionName- name of functionarguments- list of arguments to pass to the functionliteral- value to compare- Returns:
- result of equals operation between
functionNameresult andliteral
-
propertyIsNotEqualTo
- Parameters:
propertyName- name of property to compareliteral- value to compareisCaseSensitive- case-sensitivity boolean- Returns:
- result of not equals operation between
propertyNameandliteral - See Also:
-
propertyIsNotEqualTo
- Parameters:
propertyName- name of property to compareliteral- value to compare- Returns:
- result of not equals operation between
propertyNameandliteral - See Also:
-
propertyIsNotEqualTo
- Parameters:
propertyName- name of property to comparestartDate- starting date of literal to compareendDate- ending date of literal to compare- Returns:
- result of not equals operation between
propertyNameandliteral - See Also:
-
propertyIsNotEqualTo
- Parameters:
propertyName- name of property to compareliteral- value to compare- Returns:
- result of not equals operation between
propertyNameandliteral - See Also:
-
propertyIsNotEqualTo
- Parameters:
propertyName- name of property to compareliteral- value to compare- Returns:
- result of not equals operation between
propertyNameandliteral - See Also:
-
propertyIsNotEqualTo
- Parameters:
propertyName- name of property to compareliteral- value to compare- Returns:
- result of not equals operation between
propertyNameandliteral - See Also:
-
propertyIsNotEqualTo
- Parameters:
propertyName- name of property to compareliteral- value to compare- Returns:
- result of not equals operation between
propertyNameandliteral - See Also:
-
propertyIsNotEqualTo
- Parameters:
propertyName- name of property to compareliteral- value to compare- Returns:
- result of not equals operation between
propertyNameandliteral - See Also:
-
propertyIsNotEqualTo
- Parameters:
propertyName- name of property to compareliteral- value to compare- Returns:
- result of not equals operation between
propertyNameandliteral - See Also:
-
propertyIsNotEqualTo
- Parameters:
propertyName- name of property to compareliteral- value to compare- Returns:
- result of not equals operation between
propertyNameandliteral - See Also:
-
propertyIsNotEqualTo
Compares the value associated with a property is not equal to the value of a literal.propertyName != literal- Parameters:
propertyName- name of property to compareliteral- value to compare- Returns:
- result of not equals operation between
propertyNameandliteral
-
propertyIsGreaterThan
- Parameters:
propertyName- name of property to compareliteral- value to compare- Returns:
- result of greater than operation between
propertyNameandliteral - See Also:
-
propertyIsGreaterThan
- Parameters:
propertyName- name of property to compareliteral- value to compare- Returns:
- result of greater than operation between
propertyNameandliteral - See Also:
-
propertyIsGreaterThan
- Parameters:
propertyName- name of property to compareliteral- value to compare- Returns:
- result of greater than operation between
propertyNameandliteral - See Also:
-
propertyIsGreaterThan
- Parameters:
propertyName- name of property to compareliteral- value to compare- Returns:
- result of greater than operation between
propertyNameandliteral - See Also:
-
propertyIsGreaterThan
- Parameters:
propertyName- name of property to compareliteral- value to compare- Returns:
- result of greater than operation between
propertyNameandliteral - See Also:
-
propertyIsGreaterThan
- Parameters:
propertyName- name of property to compareliteral- value to compare- Returns:
- result of greater than operation between
propertyNameandliteral - See Also:
-
propertyIsGreaterThan
- Parameters:
propertyName- name of property to compareliteral- value to compare- Returns:
- result of greater than operation between
propertyNameandliteral - See Also:
-
propertyIsGreaterThan
Compares the value associated with a property is greater than the value of a literal.propertyName > literal- Parameters:
propertyName- name of property to compareliteral- value to compare- Returns:
- result of greater than operation between
propertyNameandliteral
-
propertyIsGreaterThanOrEqualTo
- Parameters:
propertyName- name of property to compareliteral- value to compare- Returns:
- result of greater than operation between
propertyNameandliteral - See Also:
-
propertyIsGreaterThanOrEqualTo
- Parameters:
propertyName- name of property to compareliteral- value to compare- Returns:
- result of greater than operation between
propertyNameandliteral - See Also:
-
propertyIsGreaterThanOrEqualTo
- Parameters:
propertyName- name of property to compareliteral- value to compare- Returns:
- result of greater than operation between
propertyNameandliteral - See Also:
-
propertyIsGreaterThanOrEqualTo
- Parameters:
propertyName- name of property to compareliteral- value to compare- Returns:
- result of greater than operation between
propertyNameandliteral - See Also:
-
propertyIsGreaterThanOrEqualTo
- Parameters:
propertyName- name of property to compareliteral- value to compare- Returns:
- result of greater than operation between
propertyNameandliteral - See Also:
-
propertyIsGreaterThanOrEqualTo
- Parameters:
propertyName- name of property to compareliteral- value to compare- Returns:
- result of greater than operation between
propertyNameandliteral - See Also:
-
propertyIsGreaterThanOrEqualTo
- Parameters:
propertyName- name of property to compareliteral- value to compare- Returns:
- result of greater than operation between
propertyNameandliteral - See Also:
-
propertyIsGreaterThanOrEqualTo
Compares the value associated with a property is greater than or equal to the value of a literal.propertyName >= literal- Parameters:
propertyName- name of property to compareliteral- value to compare- Returns:
- result of greater than operation between
propertyNameandliteral
-
propertyIsLessThan
- Parameters:
propertyName- name of property to compareliteral- value to compare- Returns:
- result of less than operation between
propertyNameandliteral - See Also:
-
propertyIsLessThan
- Parameters:
propertyName- name of property to compareliteral- value to compare- Returns:
- result of less than operation between
propertyNameandliteral - See Also:
-
propertyIsLessThan
- Parameters:
propertyName- name of property to compareliteral- value to compare- Returns:
- result of less than operation between
propertyNameandliteral - See Also:
-
propertyIsLessThan
- Parameters:
propertyName- name of property to compareliteral- value to compare- Returns:
- result of less than operation between
propertyNameandliteral - See Also:
-
propertyIsLessThan
- Parameters:
propertyName- name of property to compareliteral- value to compare- Returns:
- result of less than operation between
propertyNameandliteral - See Also:
-
propertyIsLessThan
- Parameters:
propertyName- name of property to compareliteral- value to compare- Returns:
- result of less than operation between
propertyNameandliteral - See Also:
-
propertyIsLessThan
- Parameters:
propertyName- name of property to compareliteral- value to compare- Returns:
- result of less than operation between
propertyNameandliteral - See Also:
-
propertyIsLessThan
Compares the value associated with a property is less than the value of a literal.propertyName < literal- Parameters:
propertyName- name of property to compareliteral- value to compare- Returns:
- result of less than operation between
propertyNameandliteral
-
propertyIsLessThanOrEqualTo
- Parameters:
propertyName- name of property to compareliteral- value to compare- Returns:
- result of less than or equal to operation between
propertyNameandliteral - See Also:
-
propertyIsLessThanOrEqualTo
- Parameters:
propertyName- name of property to compareliteral- value to compare- Returns:
- result of less than or equal to operation between
propertyNameandliteral - See Also:
-
propertyIsLessThanOrEqualTo
- Parameters:
propertyName- name of property to compareliteral- value to compare- Returns:
- result of less than or equal to operation between
propertyNameandliteral - See Also:
-
propertyIsLessThanOrEqualTo
- Parameters:
propertyName- name of property to compareliteral- value to compare- Returns:
- result of less than or equal to operation between
propertyNameandliteral - See Also:
-
propertyIsLessThanOrEqualTo
- Parameters:
propertyName- name of property to compareliteral- value to compare- Returns:
- result of less than or equal to operation between
propertyNameandliteral - See Also:
-
propertyIsLessThanOrEqualTo
- Parameters:
propertyName- name of property to compareliteral- value to compare- Returns:
- result of less than or equal to operation between
propertyNameandliteral - See Also:
-
propertyIsLessThanOrEqualTo
- Parameters:
propertyName- name of property to compareliteral- value to compare- Returns:
- result of less than or equal to operation between
propertyNameandliteral - See Also:
-
propertyIsLessThanOrEqualTo
Compares the value associated with a property is less than or equal to the value of a literal.propertyName <= literal- Parameters:
propertyName- name of property to compareliteral- value to compare- Returns:
- result of less than or equal to operation between
propertyNameandliteral
-
propertyIsBetween
- Parameters:
propertyName- name of property to comparelowerBoundary- lower boundary to compareupperBoundary- upper boundary to compare- Returns:
- result of between operation
- See Also:
-
propertyIsBetween
- Parameters:
propertyName- name of property to comparelowerBoundary- lower boundary to compareupperBoundary- upper boundary to compare- Returns:
- result of between operation
- See Also:
-
propertyIsBetween
- Parameters:
propertyName- name of property to comparelowerBoundary- lower boundary to compareupperBoundary- upper boundary to compare- Returns:
- result of between operation
- See Also:
-
propertyIsBetween
- Parameters:
propertyName- name of property to comparelowerBoundary- lower boundary to compareupperBoundary- upper boundary to compare- Returns:
- result of between operation
- See Also:
-
propertyIsBetween
- Parameters:
propertyName- name of property to comparelowerBoundary- lower boundary to compareupperBoundary- upper boundary to compare- Returns:
- result of between operation
- See Also:
-
propertyIsBetween
- Parameters:
propertyName- name of property to comparelowerBoundary- lower boundary to compareupperBoundary- upper boundary to compare- Returns:
- result of between operation
- See Also:
-
propertyIsBetween
- Parameters:
propertyName- name of property to comparelowerBoundary- lower boundary to compareupperBoundary- upper boundary to compare- Returns:
- result of between operation
- See Also:
-
propertyIsBetween
Compares the value associated with a property is between a lower and upper boundary. This is an exclusive comparison.lower < propertyName < upper- Parameters:
propertyName- name of property to comparelowerBoundary- lower boundary to compareupperBoundary- upper boundary to compare- Returns:
- result of between operation
-
propertyIsNull
Compares the value associated with a property is equal tonull.propertyName == null- Parameters:
propertyName- name of property to compare- Returns:
- result of null check
-
propertyIsLike
Compares the value associated with a property to a regular expression pattern.Regular expression special characters are defined as
WILDCARD_CHAR,SINGLE_CHAR, andESCAPE_CHAR.- Parameters:
propertyName- name of property to comparepattern- regular expression pattern to matchisCaseSensitive- case-sensitivity boolean- Returns:
- result of regular expression operation
-
propertyIsFuzzy
Compares the value associated with a property to the value of a literal with a fuzzy operator which expands the literal to match misspellings.- Parameters:
propertyName- name of property to compareliteral- value to compare- Returns:
- result of fuzzy operation
-
xpathExists
Deprecated.Determines if a node expressed by XPath exists.- Parameters:
xpath- XPath expression- Returns:
- result of XPath node existence
-
xpathIsLike
Deprecated.Compares the node expressed by XPath to a regular expression pattern.- Parameters:
xpath- XPath expressionpattern- regular expression pattern to matchisCaseSensitive- case-sensitivity boolean- Returns:
- result of regular expression operation on XPath node
- See Also:
-
xpathIsFuzzy
Deprecated.Compares the node expressed by XPath to the value of a literal with a fuzzy operator which expands the literal to match misspellings.- Parameters:
xpath- XPath expressionliteral- value to compare- Returns:
- result of fuzzy operation on XPath node
-
beyond
Compares the geometry associated with a property is beyond a distance from a WKT geometry.- Parameters:
propertyName- name of property to comparewkt- WKT geometry to comparedistance- distance buffer in meters- Returns:
- result of beyond spatial operation
-
contains
Compares the geometry associated with a property is contained by a WKT geometry.- Parameters:
propertyName- name of property to comparewkt- WKT geometry to compare- Returns:
- result of contains spatial operation
-
crosses
Compares the geometry associated with a property crosses a WKT geometry.- Parameters:
propertyName- name of property to comparewkt- WKT geometry to compare- Returns:
- result of crosses spatial operation
-
disjoint
Compares the geometry associated with a property is disjoint from a WKT geometry.- Parameters:
propertyName- name of property to comparewkt- WKT geometry to compare- Returns:
- result of disjoint spatial operation
-
dwithin
Compares the geometry associated with a property is within a distance from a WKT geometry.- Parameters:
propertyName- name of property to comparewkt- WKT geometry to comparedistance- distance buffer in meters- Returns:
- result of dwithin spatial operation
-
intersects
Compares the geometry associated with a property intersects a WKT geometry.- Parameters:
propertyName- name of property to comparewkt- WKT geometry to compare- Returns:
- result of intersects spatial operation
-
overlaps
Compares the geometry associated with a property overlaps a WKT geometry.- Parameters:
propertyName- name of property to comparewkt- WKT geometry to compare- Returns:
- result of overlaps spatial operation
-
touches
Compares the geometry associated with a property touches a WKT geometry.- Parameters:
propertyName- name of property to comparewkt- WKT geometry to compare- Returns:
- result of touches spatial operation
-
within
Compares the geometry associated with a property is within a WKT geometry.- Parameters:
propertyName- name of property to comparewkt- WKT geometry to compare- Returns:
- result of within spatial operation
-
after
Compares the value associated with a property is after a givenDate. This is an exclusive comparison.property > date- Parameters:
propertyName- name of property to comparedate-Dateto compare- Returns:
- result of after temporal operation
-
before
Compares the value associated with a property is before a givenDate.This is an exclusive comparison.property < date- Parameters:
propertyName- name of property to comparedate-Dateto compare- Returns:
- result of before temporal operation
-
during
Compares the value associated with a property is between a start and end date. This is an exclusive comparison.startDate < property < endDate- Parameters:
propertyName- name of property to comparestartDate- start date to compareendDate- end date to compare- Returns:
- result of during temporal operation
-
begins
Compares the value associated with the property by checking if it is start at the start date and ends some time before the endDate- Parameters:
propertyName- name of property to comparestartDate- start date to compareendDate- end date to compare- Returns:
- result of begins temporal operation
-
relative
Compares the value associated with a property is relatively within a duration of milliseconds in the past from the current time of evaluation.- Parameters:
propertyName- name of property to compareduration- relative duration in milliseconds- Returns:
- result of relative temporal operation
-