Package eu.bandm.tools.paisley
Class Observable<A>
java.lang.Object
eu.bandm.tools.paisley.Pattern<A>
eu.bandm.tools.paisley.Observable<A>
- All Implemented Interfaces:
Serializable,Cloneable
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class eu.bandm.tools.paisley.Pattern
Pattern.Either<A> -
Field Summary
Fields inherited from class eu.bandm.tools.paisley.Pattern
_left_matched, _target_save, none -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription(package private) voidvoidclear(boolean recursively) Disposes of all internal state related to results and nondeterminism.(package private) booleanisBound()booleanChecks whether this pattern is deterministic.booleanAttempts to match this pattern against a given object.booleanAttempts to re-match this pattern against a previously matched object.toString()Methods inherited from class eu.bandm.tools.paisley.Pattern
all, all, all, all, all, and, andThen, andThen, any, aside, binds, both, clear, clone, compile, compileClear, compileClear, compileCut, compileCut, compileIsDeterministic, compileMatch, compileMatchAgain, compileSubPattern, compileThis, compileUpTo, cut, cut, DEBUG, either, enPassant, flatten, limit, main, matchOnce, matchVar, narrow, newAll, noMatch, none, of, once, or, orElse, orElse, preserves, preserves, repeat, some, some, some, some, someMatch, startCompile, uniquely, variable, variable
-
Constructor Details
-
Observable
-
-
Method Details
-
addObserver
-
isBound
boolean isBound() -
match
Description copied from class:PatternAttempts to match this pattern against a given object. If the class of this pattern imposes a specific order on matches, the first one is chosen. -
matchAgain
public boolean matchAgain()Description copied from class:PatternAttempts to re-match this pattern against a previously matched object. If the class of this pattern imposes a specific order on matches, they are chosen in that order, beginning with the second one. The behaviour of this method is unspecified if the last matching attempt of this pattern has not been successful.Patterns classes that do not override this method are deterministic. Pattern classes that overwrite this method to provide additional matches should also override
Pattern.isDeterministic().- Overrides:
matchAgainin classPattern<A>- Returns:
trueif the matching is successful,falseif it fails. WhichVariables are bound by a successful match depends. The default implementation always returnsfalse.- See Also:
-
isDeterministic
public boolean isDeterministic()Description copied from class:PatternChecks whether this pattern is deterministic.The default implementation returns
true.- Overrides:
isDeterministicin classPattern<A>- Returns:
trueif this pattern is guaranteed to match any object at most once,falseotherwise.- See Also:
-
clear
public void clear(boolean recursively) Description copied from class:PatternDisposes of all internal state related to results and nondeterminism.The default implementation does nothing.
-
toString
-