Debugging Models
Launch
Follow one of these steps:
- Right click in an open editor, or on a .poosl file in the Project Explorer. Select "Run As" -> "POOSL Simulation".
- If the POOSL Model is opened in the editor, click on the small arrow next to the Debug button and select "Debug as..." -> "POOSL Simulation".
- Click on the small arrow next to the Debug button, and select the POOSL Model (if present).
- Click on the Debug button, or use keyboard shortcut <F11>, to debug the most recently launched simulation.
The launch configuration will be automatically created. You can change the launch settings in the launch configuration.
Then Eclipse switches to the POOSL Debug perspective, and the model will start in the paused state. To return to the POOSL Edit perspective, click on the POOSL Edit perspective button in the top right corner.
If this button is not visible, then it can be added via Window -> Perspective -> Open Perspective -> Other... -> POOSL Edit.
Control
The debugging starts the simulation in the paused state. The following buttons in the Eclipse tool-bar change the state of the simulation:
- Click the play button (<F8>) to resume simulation.
- Click the pause button (<F9>) to suspend simulation.
- Click the terminate button (<CTRL>-<F2>) to terminate the simulation.
- Click the step button (<F5>) to execute a single transition in one of the processes of the simulation.
- Click the time step button (<F6>) to advance the simulation to the next possible delay transition, and execute a single delay transition.
- Click the communication step button (<F7>) to advance the simulation to the next communication transition, and execute a single communication transition.
- Click the "Record Communications (for Sequence Diagram and Communication Diagram)" button in the toolbar to enable/disable the display of communication messages in the Sequence Diagram and the Communication Diagrams. Enabled provides more debugging information, whereas disabled improves the speed of the simulation.
A process step (any transition for a specific process) can be performed using the Debug view and the Execution Tree view. A specific transition of a process can be performed using the Execution Tree view.
It is possible that the simulator encounters a runtime exception during simulation. This will pause the model, such that the user can still inspect the processes, and report the exception in a pop-up. When the simulation is in this error state, clicking any of these control buttons will only show the pop-up with the exception again; no transitions are performed anymore.
To switch back to the POOSL Edit perspective, use the buttons described earlier on this page under the header "Launch".
Monitor
The progress of the simulation can be monitored using multiple views:
For non-interactive simulation, use Run a POOSL Model instead.
Advanced features