public abstract class SubstringMatcher extends TypeSafeMatcher<String>
Modifier | Constructor and Description |
---|---|
protected |
SubstringMatcher(String substring) |
Modifier and Type | Method and Description |
---|---|
void |
describeMismatchSafely(String item,
Description mismatchDescription)
Subclasses should override this.
|
void |
describeTo(Description description)
Generates a description of the object.
|
protected abstract boolean |
evalSubstringOf(String string) |
boolean |
matchesSafely(String item)
Subclasses should implement this.
|
protected abstract String |
relationship() |
describeMismatch, matches
_dont_implement_Matcher___instead_extend_BaseMatcher_, toString
protected final String substring
protected SubstringMatcher(String substring)
public boolean matchesSafely(String item)
TypeSafeMatcher
matchesSafely
in class TypeSafeMatcher<String>
public void describeMismatchSafely(String item, Description mismatchDescription)
TypeSafeMatcher
describeMismatchSafely
in class TypeSafeMatcher<String>
public void describeTo(Description description)
SelfDescribing
description
- The description to be built or appended to.protected abstract boolean evalSubstringOf(String string)
protected abstract String relationship()