In file /home/blah/darwin2k/src/d2k/d2kcore/cfgComponent.h:cfgComponent - runtime objects that are created by d2kComponents or modules.
Inheritance:
Public Fields
-
synObject* owner
- the creator or owner of the component
-
configuration* cfg
- the configuration of which the cfgComponent is a part
-
d2kSimulator* ev
- the d2kSimulator simulating the configuration
-
const char* label
- an optional name for the component
-
int active
- indicates whether the cfgComponent is currently active
Public Methods
-
~cfgComponent(void)
- destructor
-
virtual int init(void)
- performs class-specific initialization.
-
virtual int update(int &violated)
- This function is called each time step of simulation to allow the cfgComponent to update state-dependent variables.
Public Fields
-
static int staticClassID
-
int objectID
-
int verboseLevel
Public Methods
-
virtual const char* className(void) const
-
virtual synObject* copy(void) const
-
virtual int isOfType(int typeNum, int derivedOk)
-
static int setStaticClassID(void)
-
virtual int classID(void) const
Documentation
cfgComponent - runtime objects that are created by d2kComponents or
modules. For example, a sensor that is part of a module can be
implemented as a cfgComponent, and the sensor will be updated at
each simulation timestep.
- synObject* owner
- the creator or owner of the component
- configuration* cfg
- the configuration of which the cfgComponent is a part
- d2kSimulator* ev
- the d2kSimulator simulating the configuration
- const char* label
- an optional name for the component
- int active
- indicates whether the cfgComponent is currently active
- ~cfgComponent(void)
- destructor
- virtual int init(void)
- performs class-specific initialization.
This method is called after modules and all cfgComponents
have been instantiated, and after d2kComponent::init() is called.
This allows d2kComponents to create cfgComponents too.
- Returns:
- Returns 1 on success, 0 on failure
- virtual int update(int &violated)
- This function is called each time step of simulation to
allow the cfgComponent to update state-dependent variables.
If a condition is detected that requires the simulation to
be backed up to a previous timestep, violated should be
set to -1 by this method. Otherwise, it should be set to
0.
- This class has no child classes.
Alphabetic index HTML hierarchy of classes or Java
This page was generated with the help of DOC++.