S
- The type of the object that is being matched.public static interface ElementMatcher.Junction<S> extends ElementMatcher<S>
ElementMatcher
s in a readable manner.Modifier and Type | Interface and Description |
---|---|
static class |
ElementMatcher.Junction.AbstractBase<V>
A base implementation of
ElementMatcher.Junction . |
static class |
ElementMatcher.Junction.Conjunction<W>
A conjunction matcher which only matches an element if both represented matchers constitute a match.
|
static class |
ElementMatcher.Junction.Disjunction<W>
A disjunction matcher which only matches an element if both represented matchers constitute a match.
|
ElementMatcher.Junction<S>
Modifier and Type | Method and Description |
---|---|
<U extends S> |
and(ElementMatcher<? super U> other)
Creates a conjunction where this matcher and the
other matcher must both be matched in order
to constitute a successful match. |
<U extends S> |
or(ElementMatcher<? super U> other)
Creates a disjunction where either this matcher or the
other matcher must be matched in order
to constitute a successful match. |
matches
<U extends S> ElementMatcher.Junction<U> and(ElementMatcher<? super U> other)
other
matcher must both be matched in order
to constitute a successful match. The other matcher is only invoked if this matcher constitutes a successful
match.U
- The type of the object that is being matched. Note that Java's type inference might not
be able to infer the common subtype of this instance and the other
matcher such that
this type must need to be named explicitly.other
- The second matcher to consult.<U extends S> ElementMatcher.Junction<U> or(ElementMatcher<? super U> other)
other
matcher must be matched in order
to constitute a successful match. The other matcher is only invoked if this matcher constitutes an
unsuccessful match.U
- The type of the object that is being matched. Note that Java's type inference might not
be able to infer the common subtype of this instance and the other
matcher such that
this type must need to be named explicitly.other
- The second matcher to consult.Copyright © 2014–2016. All rights reserved.