class devssim

The devssim functions as the root coordinator for a simulation.

Public Methods

[more] devssim(devs* model, TIME_TYPE t0 = ZERO)
Creates and initializes a simulator for the model with initial time t0
[more]void step(TIME_TYPE dt)
Step the simulator by dt units of time.
[more]void step(TIME_TYPE dt, const adevs_bag<PortValue>& input)
Steps the simulator after applying the PortValues in the input list to the top level model.
[more]void run(TIME_TYPE t_max = INFINITY)
[more]TIME_TYPE timeCurrent()
Returns the current simulation time
[more]TIME_TYPE timeNext()
Returns the time of next event
[more]TIME_TYPE timeLast()
Returns the time of of the last event
[more]bool isPassive()
Returns true if tN = INFINITY, false otherwise
[more]virtual void reset(TIME_TYPE t0 = ZERO)
Resets the simulator (reinitialize all models for another run)
[more]virtual bool halt()
Returns true if the simulator should stop, false otherwise.
[more]virtual ~devssim()


Documentation

The devssim functions as the root coordinator for a simulation. In generally, it should not be sub-classed, except to override the halt() method.
o devssim(devs* model, TIME_TYPE t0 = ZERO)
Creates and initializes a simulator for the model with initial time t0

ovoid step(TIME_TYPE dt)
Step the simulator by dt units of time. Throws an adevs_exception if dt < 0 or if (timeCurrent() + dt) > timeNext().

ovoid step(TIME_TYPE dt, const adevs_bag<PortValue>& input)
Steps the simulator after applying the PortValues in the input list to the top level model.

ovoid run(TIME_TYPE t_max = INFINITY)

oTIME_TYPE timeCurrent()
Returns the current simulation time

oTIME_TYPE timeNext()
Returns the time of next event

oTIME_TYPE timeLast()
Returns the time of of the last event

obool isPassive()
Returns true if tN = INFINITY, false otherwise

ovirtual void reset(TIME_TYPE t0 = ZERO)
Resets the simulator (reinitialize all models for another run)

ovirtual bool halt()
Returns true if the simulator should stop, false otherwise. This method is called by the root coordinator/simulator at the end of each simulation cycle.

ovirtual ~devssim()


This class has no child classes.

Alphabetic index HTML hierarchy of classes or Java



This page was generated with the help of DOC++.