NeuroLab
EventMultiplexer Class Reference
Inheritance diagram for EventMultiplexer:

Public Member Functions

 EventMultiplexer (Time *time, const string &name="", const string &type="Event Mulitplexer")
 
virtual ~EventMultiplexer ()
 
virtual bool hasEvent ()
 Wether the process has an event. More...
 
virtual uint getEventAmount ()
 The amount of events. More...
 
virtual void prepareNextState ()
 Calculate the value for the next time step.
 
bool addSource (StochasticEventGenerator *)
 Add a source event source. More...
 
bool removeSource (StochasticEventGenerator *)
 Remove a source event source. More...
 
- Public Member Functions inherited from StochasticEventGenerator
 StochasticEventGenerator (class Time *time, const string &name="", const string &type="Event Generator")
 Create.
 
virtual ~StochasticEventGenerator ()
 Destroy.
 
- Public Member Functions inherited from StochasticVariable
 StochasticVariable (class Time *time, const string &name="", const string &type="Stochastic Variable")
 Create.
 
double operator() ()
 Returns the value at the current time step. More...
 
double d ()
 Returns the increment at the current time step. More...
 
- Public Member Functions inherited from StochasticProcess
 StochasticProcess (class Time *time, const string &name="", const string &type="Stochastic")
 Create.
 
virtual ~StochasticProcess ()
 Destroy.
 
virtual void proceedToNextState ()
 Proceed one time step. More...
 
bool isNextStatePrepared ()
 Whether.
 
virtual double getIncrement ()
 Returns the increment. More...
 
virtual double getCurrentValue ()
 Returns the value of the process. More...
 
virtual double getNextValue ()
 Returns the next value of the process. More...
 
virtual void setNextValue (double d)
 Set the next value of the process. More...
 
virtual void setCurrentValue (double d)
 Set the current value of the process. More...
 
void setDescription (string s)
 Set stochastic description.
 
virtual void init ()
 Initialise time-dependent values.
 
string getDescription ()
 Get the name. More...
 
- Public Member Functions inherited from Parametric
string getType () const
 Type of object.
 
string getName () const
 Name of object.
 
void setName (const string &name)
 Name of object.
 
string getConfiguration () const
 Returns the configuration of the object. More...
 
string getAllParameters () const
 String with all parameter settings.
 
void addParameter (const string &name)
 Add a parameter. More...
 
void rmParameter (const string &name)
 Remove a parameter. More...
 
virtual void setParameter (const string &name, const string &value)
 Set parameter. More...
 
virtual string getParameter (const string &name) const
 Get parameter. More...
 
- Public Member Functions inherited from TimeDependent
 TimeDependent (class Time *time)
 Construct. More...
 
virtual class TimegetTime () const
 Return pointer to the time object.
 
- Public Member Functions inherited from Physical
 Physical ()
 Construct.
 
 Physical (const Physical &)
 Copy.
 
 Physical (string name)
 Construct.
 
 Physical (string name, string unitPrefix, string unitSymbol)
 Construct.
 
 Physical (string name, Unit unit)
 Construct.
 
virtual string getPhysicalDescription ()
 Returns the physical description. More...
 
virtual string getUnitName ()
 Returns the unit name.
 
virtual string getUnitSymbol ()
 Returns the unit name.
 
virtual void setPhysicalDescription (string name)
 Set the name. Same as setDescription(). More...
 
virtual void setUnit (Unit u)
 Set the unit.
 
virtual void setUnitPrefix (int n)
 Set unit prefix. More...
 
virtual Unit getUnit () const
 Retrieve the unit.
 

Additional Inherited Members

- Protected Member Functions inherited from Parametric
 Parametric (const string &name, const string &type)
 Create object of type and name.
 
virtual ~Parametric ()
 Destroy object.
 
- Protected Attributes inherited from StochasticProcess
double stochCurrentValue
 the current value
 
double stochNextValue
 the next value (direct future)
 
bool stochNextStateIsPrepared
 whether prepareNextState() was successful
 
string stochDescription
 the name of the quantity
 

Detailed Description

Mulitplexer for various event sources Uses several input processes that generate events and produces a train of response events which is a sum of its inputs. Each time point any of the source processes has an event, this class has an event too. If several sources have an event, the getEventAmount() function will return the appropriate number.

Constructor & Destructor Documentation

EventMultiplexer::EventMultiplexer ( Time time,
const string &  name = "",
const string &  type = "Event Mulitplexer" 
)

Constructor Create an instance.

virtual EventMultiplexer::~EventMultiplexer ( )
inlinevirtual

Destructor Destroy an instance.

Member Function Documentation

bool EventMultiplexer::addSource ( StochasticEventGenerator )

Add a source event source.

Returns true if successful, otherwise false.

virtual uint EventMultiplexer::getEventAmount ( )
virtual

The amount of events.

Returns the difference of the value in the next time step to the value in the current time step.

Reimplemented from StochasticEventGenerator.

virtual bool EventMultiplexer::hasEvent ( )
virtual

Wether the process has an event.

Each event process is a counting process. If any of the source processes has an event (i.e. the value in the next time step is higher than the value in the current time step), this class has an event two (its value in the next time step will be higher than its value in the current time step.

Reimplemented from StochasticEventGenerator.

bool EventMultiplexer::removeSource ( StochasticEventGenerator )

Remove a source event source.

Returns true if successful, otherwise false.