ControlPanel -- Class to control the top level SwarmProcess
Description
ControlPanel keeps track of the users requests to run, stop, quit, or time step the simulation. It cooperates with the GUISwarm to control the execution of activities in Swarm.
- getState Get the current button state of the controlpanel. Is one of ControlStateRunning, ControlStateStopped, ControlStateStepping, ControlStateNextTime, or ControlStateQuit.
- setState:s
- startInActivity:activityID
- setStateRunning Sets the state to `running'.
- setStateStopped The -setStateStopped message is particularly useful since it will cause the simulation to stop until the user interactively sets it back in motion (in other words, this method is useful in generating a software-triggered pause).
- setStateStepping Stop the running activity, and then set state to `ControlStateStepping'.
- setStateQuit Terminate activities, and set state to `ControlStateQuit'.
- setStateNextTime Stop the running activity, and then set state to `ControlStateNextTime'.
- setStateSave Saves the objects that are registered for archiving.