|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectmain.ModelRunner
Field Summary | |
Integrator |
integrator
|
boolean |
running
|
java.lang.Thread |
runThread
|
SimpleStop |
stopper
|
Constructor Summary | |
ModelRunner(Model model,
SimpleStop stopper)
|
Method Summary | |
void |
checkForNaN()
Checks through all nodes of all cells in the model to see whether any of them have out of range numbers (NaN). |
void |
doReset()
|
void |
doRun()
This has the code which actually runs a model. |
void |
doStartRun()
Call doStartRun() to initialize a model for running it. |
void |
doStep()
|
Cell[] |
getCells()
|
Model |
getModel()
|
int |
getNumCells()
|
int |
getNumNodes()
|
SimpleStop |
getStopper()
|
boolean |
isRunning()
Returns true if the model is currently running |
void |
run()
No other class should call run() directly. |
void |
setRunMode(java.lang.String rm)
|
void |
setStopper(SimpleStop stopper)
|
void |
startRun()
These next functions wrap the running of a model inside a thread. |
void |
stopRun()
Call stopRun() to stop a model that's currently running. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public java.lang.Thread runThread
public Integrator integrator
public SimpleStop stopper
public boolean running
Constructor Detail |
public ModelRunner(Model model, SimpleStop stopper)
Method Detail |
public void setStopper(SimpleStop stopper)
public SimpleStop getStopper()
public void startRun()
public void run()
run
in interface java.lang.Runnable
public void stopRun()
public boolean isRunning()
public void doStartRun()
public void doReset()
public void doRun() throws java.lang.Exception
java.lang.Exception
public void doStep() throws java.lang.Exception
java.lang.Exception
public void checkForNaN() throws java.lang.Exception
java.lang.Exception
public void setRunMode(java.lang.String rm)
public Model getModel()
public Cell[] getCells()
public int getNumCells()
public int getNumNodes()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |