T - public interface QuickDiagnosingMatcher<T>
extends org.hamcrest.Matcher<T>
Matcher that is able to match and diagnose in one step, but, unlike
DiagnosingMatcher, also provides an efficient implementation for the
simple match.
The matcher is also able to provide a MatchResult that caches
all relevant information about the match.
Implementations of this interface should extend
QuickDiagnosingMatcherBase.
See this class for more implementation tips.
| Modifier and Type | Method and Description |
|---|---|
boolean |
matches(Object item,
org.hamcrest.Description mismatch)
Evaluates the matcher for argument
item. |
<I> MatchResult<I> |
matchResult(I item)
Returns a
MatchResult for item |
boolean matches(Object item, org.hamcrest.Description mismatch)
item.
A mismatch description is appended to mismatch
if and only if the match fails.
item - The object against which the matcher is evaluated.mismatch - The description to be built or appended to.true if item matches, otherwise false.<I> MatchResult<I> matchResult(I item)
MatchResult for itemI - item - Copyright © 2015. All rights reserved.