simulator.resume() should resume even if no listeners active
The experiment developer has full control over the number of active listeners. simulator.resume() therefore should resume simulation even if it won't ever return. git-svn-id: https://www4.informatik.uni-erlangen.de/i4svn/danceos/trunk/devel/fail@1574 8c4709b5-6ec9-48aa-a5cd-a96041d1645a
This commit is contained in:
@ -21,8 +21,6 @@ bool SimulatorController::addListener(BaseListener* li)
|
||||
|
||||
BaseListener* SimulatorController::resume(void)
|
||||
{
|
||||
if (!hasListeners())
|
||||
return NULL;
|
||||
m_Flows.resume();
|
||||
assert(m_LstList.getLastFired() != NULL &&
|
||||
"FATAL ERROR: getLastFired() expected to be non-NULL!");
|
||||
|
||||
@ -202,10 +202,10 @@ public:
|
||||
void clearListeners(ExperimentFlow *flow = 0) { m_LstList.remove(flow); }
|
||||
/**
|
||||
* Switches the control flow to the simulator and waits on any listeners
|
||||
* which have been added to the listener management. If one of those listeners
|
||||
* occurs, resume() will return the pointer of that listener.
|
||||
* @return the previously occurred listener, or \c NULL if there are no
|
||||
* listeners to wait for
|
||||
* which have been added to the listener management. If one of those listeners
|
||||
* occurs, resume() will return the pointer of that listener. If there are
|
||||
* no more active listeners for this experiment, resume() never returns.
|
||||
* @return the previously occurred listener
|
||||
*/
|
||||
BaseListener* resume();
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user