public abstract class MergeableState<T> extends Object
Constructor and Description |
---|
MergeableState() |
Modifier and Type | Method and Description |
---|---|
void |
afterSplit(AbstractBeginNode node)
This method is called before the successors of a
ControlSplitNode are visited. |
abstract T |
clone() |
void |
loopBegin(LoopBeginNode loopBegin)
This method is called before a loop is entered (before the
LoopBeginNode is visited). |
void |
loopEnds(LoopBeginNode loopBegin,
List<T> loopEndStates)
This method is called after all
LoopEndNode s belonging to a loop have been visited. |
abstract boolean |
merge(AbstractMergeNode merge,
List<T> withStates)
This method is called on merge on the state of the first branch.
|
public MergeableState()
public abstract boolean merge(AbstractMergeNode merge, List<T> withStates)
withStates
list
contains the states of the of the other branches in the order of the merge's end nodes.merge
- the merge nodewithStates
- the state at the the merge's end node except the first one.public void loopBegin(LoopBeginNode loopBegin)
LoopBeginNode
is visited).loopBegin
- the begin node of the looppublic void loopEnds(LoopBeginNode loopBegin, List<T> loopEndStates)
LoopEndNode
s belonging to a loop have been visited.loopBegin
- the begin node of the looploopEndStates
- the states at the loop ends, sorted according to
LoopBeginNode.orderedLoopEnds()
public void afterSplit(AbstractBeginNode node)
ControlSplitNode
are visited.node
- the successor of the control split that is about to be visited