|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectorg.geotools.filter.FilterAbstract
org.geotools.filter.AbstractFilter
org.geotools.filter.AbstractFilterImpl
org.geotools.filter.LikeFilterImpl
Defines a like filter, which checks to see if an attribute matches a REGEXP.
| Field Summary |
| Fields inherited from class org.geotools.filter.AbstractFilter |
filterType, LOGGER, permissiveConstruction |
| Fields inherited from interface org.geotools.filter.Filter |
ALL, NONE |
| Fields inherited from interface org.geotools.filter.FilterType |
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, NULL |
| Constructor Summary | |
protected |
LikeFilterImpl()
Constructor which flags the operator as like. |
| Method Summary | |
java.lang.Object |
accept(org.opengis.filter.FilterVisitor visitor,
java.lang.Object extraData)
Used by FilterVisitors to perform some action on this filter instance. |
static java.lang.String |
convertToSQL92(char escape,
char multi,
char single,
java.lang.String pattern)
Given OGC PropertyIsLike Filter information, construct an SQL-compatible 'like' pattern. |
boolean |
equals(java.lang.Object obj)
Compares this filter to the specified object. |
boolean |
evaluate(Feature feature)
Determines whether or not a given feature matches this pattern. |
java.lang.String |
getEscape()
Getter for property escape. |
org.opengis.filter.expression.Expression |
getExpression()
Gets the expression for hte filter. |
java.lang.String |
getLiteral()
Returns the pattern. |
java.lang.String |
getPattern()
Deprecated. use getLiteral() |
java.lang.String |
getSingleChar()
THis method calls getWildcardSingle()() for subclass backwards
compatability.
|
java.lang.String |
getSQL92LikePattern()
see convertToSQL92 |
Expression |
getValue()
Deprecated. use getExpression(). |
java.lang.String |
getWildCard()
THis method calls getWildcardMulti() for subclass backwards
compatability.
|
java.lang.String |
getWildcardMulti()
Deprecated. use getWildCard(). |
java.lang.String |
getWildcardSingle()
Deprecated. use getSingleChar() |
int |
hashCode()
Override of hashCode method. |
void |
setEscape(java.lang.String escape)
|
void |
setExpression(org.opengis.filter.expression.Expression e)
|
void |
setLiteral(java.lang.String literal)
Sets the pattern. |
void |
setPattern(Expression p,
java.lang.String wildcardMulti,
java.lang.String wildcardSingle,
java.lang.String escape)
Deprecated. use one of PropertyIsLike.setExpression(Expression)
PropertyIsLike#setWildCard(String)
{@link PropertyIsLike#setSingleChar(String)}
{@link PropertyIsLike#setEscape(String)} |
void |
setPattern(java.lang.String pattern,
java.lang.String wildcardMulti,
java.lang.String wildcardSingle,
java.lang.String escape)
Deprecated. use one of PropertyIsLike.setLiteral(String)
PropertyIsLike#setWildCard(String)
{@link PropertyIsLike#setSingleChar(String)}
{@link PropertyIsLike#setEscape(String)} |
void |
setSingleChar(java.lang.String singleChar)
|
void |
setValue(Expression attribute)
Sets the expression to be evalutated as being like the pattern |
void |
setWildCard(java.lang.String wildCard)
|
java.lang.String |
toString()
Return this filter as a string. |
| Methods inherited from class org.geotools.filter.AbstractFilterImpl |
and, not, or |
| Methods inherited from class org.geotools.filter.AbstractFilter |
accept, contains, evaluate, getFilterType, isCompareFilter, isGeometryDistanceFilter, isGeometryFilter, isLogicFilter, isMathFilter, isSimpleFilter |
| Methods inherited from class org.geotools.filter.FilterAbstract |
accepts, comparable, eval, eval |
| Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface org.geotools.filter.LikeFilter |
contains |
| Methods inherited from interface org.geotools.filter.Filter |
accept, and, getFilterType, not, or |
| Methods inherited from interface org.opengis.filter.Filter |
evaluate |
| Constructor Detail |
protected LikeFilterImpl()
| Method Detail |
public static java.lang.String convertToSQL92(char escape,
char multi,
char single,
java.lang.String pattern)
throws java.lang.IllegalArgumentException
escape - multi - single - pattern -
java.lang.IllegalArgumentException
public java.lang.String getSQL92LikePattern()
throws java.lang.IllegalArgumentException
java.lang.IllegalArgumentExceptionpublic void setWildCard(java.lang.String wildCard)
setWildCard in interface org.opengis.filter.PropertyIsLikepublic void setSingleChar(java.lang.String singleChar)
setSingleChar in interface org.opengis.filter.PropertyIsLikepublic void setEscape(java.lang.String escape)
setEscape in interface org.opengis.filter.PropertyIsLike
public final void setValue(Expression attribute)
throws IllegalFilterException
setValue in interface LikeFilterattribute - The value of the attribute for comparison.
IllegalFilterException - Filter is illegal.public final Expression getValue()
getExpression().
getValue in interface LikeFilterpublic org.opengis.filter.expression.Expression getExpression()
This method calls th deprecated getValue() for backwards
compatability with subclasses.
getExpression in interface org.opengis.filter.PropertyIsLikepublic void setExpression(org.opengis.filter.expression.Expression e)
setExpression in interface org.opengis.filter.PropertyIsLike
public final void setPattern(Expression p,
java.lang.String wildcardMulti,
java.lang.String wildcardSingle,
java.lang.String escape)
PropertyIsLike.setExpression(Expression)
PropertyIsLike#setWildCard(String)
{@link PropertyIsLike#setSingleChar(String)}
{@link PropertyIsLike#setEscape(String)}
setPattern in interface LikeFilterp - the expression which evaluates to the match pattern for this
filterwildcardMulti - the string that represents a mulitple character
(1->n) wildcardwildcardSingle - the string that represents a single character (1)
wildcardescape - the string that represents an escape character
public final void setPattern(java.lang.String pattern,
java.lang.String wildcardMulti,
java.lang.String wildcardSingle,
java.lang.String escape)
PropertyIsLike.setLiteral(String)
PropertyIsLike#setWildCard(String)
{@link PropertyIsLike#setSingleChar(String)}
{@link PropertyIsLike#setEscape(String)}
setPattern in interface LikeFilterpattern - the string which contains the match pattern for this
filterwildcardMulti - the string that represents a mulitple character
(1->n) wildcardwildcardSingle - the string that represents a single character (1)
wildcardescape - the string that represents an escape characterpublic final java.lang.String getPattern()
getLiteral()
getPattern in interface LikeFilterpublic java.lang.String getLiteral()
getLiteral in interface org.opengis.filter.PropertyIsLikepublic void setLiteral(java.lang.String literal)
setLiteral in interface org.opengis.filter.PropertyIsLikepublic boolean evaluate(Feature feature)
evaluate in interface Filterevaluate in class FilterAbstractfeature - Specified feature to examine.
public java.lang.String toString()
public java.lang.String getEscape()
getEscape in interface LikeFilterpublic final java.lang.String getWildcardMulti()
getWildCard().
getWildcardMulti in interface LikeFilterpublic java.lang.String getWildCard()
THis method calls getWildcardMulti() for subclass backwards
compatability.
getWildCard in interface org.opengis.filter.PropertyIsLikePropertyIsLike.getWildCard().public final java.lang.String getWildcardSingle()
getSingleChar()
getWildcardSingle in interface LikeFilterpublic java.lang.String getSingleChar()
THis method calls getWildcardSingle()() for subclass backwards
compatability.
getSingleChar in interface org.opengis.filter.PropertyIsLikePropertyIsLike.getSingleChar()().public boolean equals(java.lang.Object obj)
obj - - the object to compare this LikeFilter against.
public int hashCode()
public java.lang.Object accept(org.opengis.filter.FilterVisitor visitor,
java.lang.Object extraData)
accept in interface org.opengis.filter.Filteraccept in class FilterAbstractvisitor - The visitor which requires access to this filter, the
method must call visitor.visit(this);
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||