tom.library.sl
Class Mu
java.lang.Object
tom.library.sl.AbstractStrategy
tom.library.sl.AbstractStrategyCombinator
tom.library.sl.Mu
- All Implemented Interfaces:
- Strategy, Visitable
public class Mu
- extends AbstractStrategyCombinator
Basic strategy combinator used to build a recursive strategy
Visiting such a combinator fire the mu-expansion which instantiate
the MuVar variables and removed the Mu combinator
Field Summary |
static int |
V
|
static int |
VAR
|
Methods inherited from class tom.library.sl.AbstractStrategyCombinator |
getChildAt, getChildCount, getChildren, getVisitor, getVisitors, initSubterm, initSubterm, initSubterm, initSubterm, initSubterm, setChildAt, setChildren |
Methods inherited from class tom.library.sl.AbstractStrategy |
getAncestor, getEnvironment, getPosition, getRoot, getSubject, init, init, setEnvironment, setRoot, setSubject, visit, visit, visit, visit, visitLight |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
VAR
public static final int VAR
- See Also:
- Constant Field Values
V
public static final int V
- See Also:
- Constant Field Values
Mu
public Mu(Strategy var,
Strategy v)
visitLight
public final <T> T visitLight(T any,
Introspector i)
throws VisitFailure
- Description copied from interface:
Strategy
- Visit the subject any in a light way (without environment)
- Parameters:
any
- the subject to visit.
- Throws:
VisitFailure
- in case of failure.
visit
public int visit(Introspector i)
- Description copied from interface:
Strategy
- Visit the current subject (found in the environment)
and place its result in the environment.
Sets the environment flag to Environment.FAILURE in case of failure
- Parameters:
i
- the introspector
expand
public static void expand(Strategy s)