public class ConstantMatcher extends StringMatcher
StringMatcher matches any string or no string at all.| Constructor and Description |
|---|
ConstantMatcher(boolean matches)
Creates a new ConstantMatcher that always returns the given result.
|
| Modifier and Type | Method and Description |
|---|---|
protected boolean |
matches(java.lang.String string,
int beginOffset,
int endOffset)
Checks whether the given substring matches.
|
matchespublic ConstantMatcher(boolean matches)
protected boolean matches(java.lang.String string,
int beginOffset,
int endOffset)
StringMatchermatches in class StringMatcherstring - the string to match.beginOffset - the start offset of the substring (inclusive).endOffset - the end offset of the substring (exclusive).