#include <DC_Event.h>
An event class encapsulates an event report. An event report is used to store information that is generated by an application upon the occurrence of certain conditions. From an implementation point of view, an event is a container for attributes that describe the occurrence that triggered the creation of event report. This class recognizes only two such attributes:<ul> an event type identifier that defines the event category, a time stamp that defines the time when the event was created. Both attributes are read-write. Applications that need to attach more information to an event report can do so by extending this class.
Normally, to each event class is associated an event repository class that encapsulates a container for a set of event reports. The event repository class associated to the DC_Event
class is DC_EventRepository
. Events should normally be manipulated only by their associated event repository. Applications should normally have no need to directly interact with an event object.
This class is intended to be very light-weight because it may be instantiated in large numbers within an event repository. For this reason, unlike most OBS Framework classes, it is a stand-alone class which does not inherit from DC_RootObject
. This is a deviation from project-specific coding rule PR1.1.
Definition at line 49 of file DC_Event.h.
Public Member Functions | |
DC_Event (void) | |
Instantiate an event object. | |
TD_ObsTime | getTimeStamp (void) const |
Getter method for the time stamp attribute of the event. | |
TD_EventType | getEventType (void) const |
Getter method for the event identifier attribute of the event. | |
void | setTimeStamp (TD_ObsTime timeStamp) |
Setter method for the time stamp attribute of the event. | |
void | setEventType (TD_EventType eventType) |
Setter method for the event identifier attribute of the event. |
|
Instantiate an event object.
In order to minimize the overhead due to the instantiation of a
The constructor is declared Definition at line 17 of file DC_Event_inl.h. |
|
Getter method for the event identifier attribute of the event.
Definition at line 25 of file DC_Event_inl.h. |
|
Getter method for the time stamp attribute of the event.
Definition at line 20 of file DC_Event_inl.h. |
|
Setter method for the event identifier attribute of the event.
Definition at line 35 of file DC_Event_inl.h. |
|
Setter method for the time stamp attribute of the event.
Definition at line 30 of file DC_Event_inl.h. |