Package repast.simphony.ws
Class ScheduleRunner
java.lang.Object
repast.simphony.ws.ScheduleRunner
This class executes the model schedule found in the RunState's
ScheduleRegistry.
- Author:
- Nick Collier
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidaddRunListener(RunListener listener) Adds the specified listener to the list of RunListener-s to be notified of any run related events, such as stopped, started, and so on.voidThis executes the given RunState object's schedule.protected ISchedulegetSchedule(RunState toExecuteOn) booleango()Specifies if the simulation should continue to run (returns true) or if it should stop (returns false).voidinit()voidremoveRunListener(RunListener listener) Removes the specified RunListener from the list for RunListener notified by this runner.voidsetController(Controller controller) voidsetEnvironmentBuilder(RunEnvironmentBuilder environment) voidsetPause(boolean pause) voidsetTickListener(TickListener tickListener) voidstep()voidstop()
-
Field Details
-
stop
protected boolean stop -
pause
protected boolean pause -
step
protected boolean step
-
-
Constructor Details
-
ScheduleRunner
public ScheduleRunner()
-
-
Method Details
-
execute
This executes the given RunState object's schedule. It will continue executing the schedule until there are no more actions schedule or the run manager tells it to stop. -
go
public boolean go()Description copied from interface:RunnerSpecifies if the simulation should continue to run (returns true) or if it should stop (returns false). -
setPause
public void setPause(boolean pause) -
step
public void step() -
stop
public void stop() -
getTickListener
-
setTickListener
-
getSchedule
-
init
public void init() -
setEnvironmentBuilder
- Specified by:
setEnvironmentBuilderin interfaceRunner
-
addRunListener
Description copied from interface:RunnerAdds the specified listener to the list of RunListener-s to be notified of any run related events, such as stopped, started, and so on.- Specified by:
addRunListenerin interfaceRunner- Parameters:
listener- the listener to add.
-
removeRunListener
Description copied from interface:RunnerRemoves the specified RunListener from the list for RunListener notified by this runner.- Specified by:
removeRunListenerin interfaceRunner
-
setController
- Specified by:
setControllerin interfaceRunner
-