The source project of this merge request has been removed.
Failsafe Simulation run
In order to prevent stupid user mistakes leading to ever-running simulations (mostly due to a Simulator::Stop() missing), I added the following functions:
- Simulator::IsStopScheduled
- Simulator::IsRunForeverSet
- Simulator::RunForever
Each module that could prevent a simulation stop (e.g., FlowMonitor) can now implement a check to verify if there is a user mistake. The user must now call either Simulator::Stop() or Simulator::RunForever (the second to explicit acknowledge that the simulation will run forever, perhaps because there's another way to stop the simulation).
FlowMonitor already implements this.
All the RealtimeSimulatorImpl allows by default to be run forever.