public class StringMatcher extends ElementMatcher.Junction.AbstractBase<String>
StringMatcher.Mode.| Modifier and Type | Class and Description |
|---|---|
static class |
StringMatcher.Mode
Defines the mode a
StringMatcher compares to strings with. |
ElementMatcher.Junction.AbstractBase<V>, ElementMatcher.Junction.Conjunction<W>, ElementMatcher.Junction.Disjunction<W>ElementMatcher.Junction<S>| Constructor and Description |
|---|
StringMatcher(String value,
StringMatcher.Mode mode)
Creates a new string matcher.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(Object other) |
int |
hashCode() |
boolean |
matches(String target)
Matches a target against this element matcher.
|
String |
toString() |
and, orpublic StringMatcher(String value, StringMatcher.Mode mode)
value - The value that is the base of the matching.mode - The mode to apply for matching the given value against the matcher's inputpublic boolean matches(String target)
ElementMatchertarget - The instance to be matched.true if the given element is matched by this matcher or false otherwise.Copyright © 2014–2016. All rights reserved.