public static final class Query.Regex extends Object implements Query.KeyQuery
k
with a value that matches the
regex in v
. The expression will be automatically anchored to the start to encourage
prefix matches.
Warning: regular expressions are often expensive and can add a lot of overhead. Use them sparingly.
Query.And, Query.CompositeKeyQuery, Query.Equal, Query.GreaterThan, Query.GreaterThanEqual, Query.Has, Query.In, Query.InvertedKeyQuery, Query.KeyQuery, Query.LessThan, Query.LessThanEqual, Query.Not, Query.Or, Query.Regex
Modifier and Type | Method and Description |
---|---|
boolean |
alwaysMatches()
Returns true if the pattern will always match.
|
boolean |
equals(Object obj) |
int |
hashCode() |
String |
key()
Key checked by this query.
|
boolean |
matches(String value)
Returns true if the value matches for this query clause.
|
com.netflix.spectator.impl.PatternMatcher |
pattern()
Returns the pattern matcher for checking the values.
|
String |
toString() |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
matches, simplify
public String key()
Query.KeyQuery
key
in interface Query.KeyQuery
public com.netflix.spectator.impl.PatternMatcher pattern()
public boolean matches(String value)
Query.KeyQuery
matches
in interface Query.KeyQuery
public boolean alwaysMatches()