public class AlgorithmRunStack
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
protected java.util.LinkedList<AlgorithmRun> |
_runs
the list of runs
|
protected AlgorithmStrategy |
_strategy
the algorithm strategy that populated the run stack
|
Constructor and Description |
---|
AlgorithmRunStack()
Constructor
|
AlgorithmRunStack(AlgorithmRun run)
Constructor
|
AlgorithmRunStack(AlgorithmStrategy strategy)
Primary Constructor
|
Modifier and Type | Method and Description |
---|---|
void |
appendRun(AlgorithmRun anAlgorithmRun)
Add another another algorithm run to the stack.
|
void |
appendStack(AlgorithmRunStack anAlgorithmRunStack)
Add another algorithm run stack to the stack.
|
java.util.List<AlgorithmRun> |
getAlgorithmRuns()
Get the algorithm runs.
|
AlgorithmStrategy |
getAlgorithmStrategy()
Get the algorithm strategy that populated this algorithm run stack.
|
boolean |
hasNext()
Determine if there are any more algorithm runs in the algorithm run stack.
|
AlgorithmRun |
popAlgorithmRun()
Get the next algorithm to be run.
|
void |
reset()
Reset the algorithm schedule.
|
protected AlgorithmStrategy _strategy
protected java.util.LinkedList<AlgorithmRun> _runs
public AlgorithmRunStack(AlgorithmStrategy strategy)
public AlgorithmRunStack()
public AlgorithmRunStack(AlgorithmRun run)
run
- the run with which to initialize the run stackpublic void reset()
public boolean hasNext()
public void appendStack(AlgorithmRunStack anAlgorithmRunStack)
anAlgorithmRunStack
- The algorithm to add to the stack.public void appendRun(AlgorithmRun anAlgorithmRun)
anAlgorithmRun
- The algorithm to add to the stack.public java.util.List<AlgorithmRun> getAlgorithmRuns()
public AlgorithmStrategy getAlgorithmStrategy()
public AlgorithmRun popAlgorithmRun()