public abstract static class Pattern.Transform<A,B> extends Pattern.Unary<B,A> implements Function<A,B>
Pattern.Atomic<A>, Pattern.Binary<A,B,C>, Pattern.Contravariant<A>, Pattern.Proxy, Pattern.Transform<A,B>, Pattern.Unary<A,B>, Pattern.Variable<A>
body
Modifier | Constructor and Description |
---|---|
protected |
Transform(Pattern<? super B> body) |
Modifier and Type | Method and Description |
---|---|
protected boolean |
isApplicable(A x) |
boolean |
match(A x)
Attempt to match this pattern against a given object.
|
boolean |
matchAgain()
Attempt to re-match this pattern against a previously matched
object.
|
bindsVariable, clear, cut, disturbsVariable, isDeterministic, savesVariable
narrow
and, any, both, either, eq, first, forInstancesOf, limit, matchOnce, none, or, p_null, somewhere, transform, uniquely, variable, variable
public boolean match(A x)
Pattern
public boolean matchAgain()
Pattern
Patterns classes that do not overwrite this method guarantee
matchAgain
in class Pattern<A>
protected boolean isApplicable(A x)
see also the complete user documentation .