A - the target type of the containing patternB - the target type of the contained subpatternpublic abstract class Transform<A,B> extends Unary<B,A>
Subclasses must implement the apply(A) and #isApplicable methods.
| Modifier | Constructor and Description |
|---|---|
protected |
Transform(Pattern<? super B> body)
Creates a new pattern.
|
| Modifier and Type | Method and Description |
|---|---|
abstract B |
apply(A target)
Transforms a target to be matched into a target for the
subpattern.
|
protected void |
compileApply(eu.bandm.tools.paisley.CompilationContext context) |
binds, clear, clone, compileClear, compileCut, cut, getBody, isDeterministic, matchAgain, preserves, preserves, setBody, toStringall, all, all, all, all, and, andThen, andThen, any, any, aside, both, clear, compareTo, compile, compileClear, compileCut, compileIsDeterministic, compileMatch, compileMatchAgain, compileSubPattern, compileThis, compileUpTo, cut, DEBUG, either, enPassant, eq, eqNull, equal, filter, flatten, forInstancesOf, limit, main, match, matchOnce, matchVar, narrow, neq, neqNull, newAll, noMatch, none, or, orElse, orElse, repeat, some, some, some, some, someMatch, startCompile, test, transform, uniquely, variable, variablepublic abstract B apply(A target)
target - the target for this pattern to be matched against.Unary.body to be matched against.protected void compileApply(eu.bandm.tools.paisley.CompilationContext context)
see also the complete user documentation .