#include <CTimedEvent.h>
Inheritance diagram for CTimedEvent:
Public Methods | |
CTimedEvent (unsigned int nms=1000) | |
Default constructor. | |
CTimedEvent (const CTimedEvent &rhs) | |
Copy constructor. | |
virtual | ~CTimedEvent () |
Destructor. | |
CTimedEvent & | operator= (const CTimedEvent &rhs) |
Assignment. | |
int | operator== (const CTimedEvent &rhs) const |
Comparison for equality. | |
int | operator!= (const CTimedEvent &rhs) const |
unsigned int | getMsInterval () const |
unsigned int | getCountDown () const |
void | Tick (unsigned int nms) |
void | SetInterval (unsigned int nms) |
void | Reset () |
virtual void | operator() ()=0 |
Protected Methods | |
void | setCountdown (unsigned int nmsleft) |
Private Attributes | |
unsigned int | m_nMsInterval |
Number of milliseconds between events. | |
int | m_nCountDown |
Number of milliseconds until next event fire. |
Timed events are to be inserted in a CTimer which will periodically call the Tick member function so that the event can schedule itself at the resolution of the timer.
Definition at line 290 of file CTimedEvent.h.
|
Default constructor. Default constructor. This is called when declarations of the form e.g.:
Definition at line 292 of file CTimedEvent.cpp. |
|
Copy constructor. Copy construction. This is invoked when e.g. an object is passed by value to a function. The copy constructor makes a clone of the rhs object. Definition at line 301 of file CTimedEvent.cpp. |
|
Destructor.
Definition at line 301 of file CTimedEvent.h. |
|
Definition at line 316 of file CTimedEvent.h. References m_nCountDown. |
|
Definition at line 312 of file CTimedEvent.h. References m_nMsInterval. |
|
Definition at line 305 of file CTimedEvent.h. References operator==(). |
|
Invoked when the timer expires. The user of this class must subclass and override this to supply application specific functionality. Implemented in CRunVariableDumpTrigger, CScalerTrigger, CamacTestThread, CamacTestThread, VMETestThread, and CPing. Referenced by Tick(). |
|
Assignment. Assignment operation. This member function supports assignment of an object of this class to an object of the same class. Definition at line 312 of file CTimedEvent.cpp. References m_nCountDown, and m_nMsInterval. |
|
Comparison for equality. Equality copmarison: Definition at line 326 of file CTimedEvent.cpp. References m_nCountDown, and m_nMsInterval. Referenced by operator!=(). |
|
Resets the countdown.
Definition at line 375 of file CTimedEvent.cpp. References m_nCountDown, and m_nMsInterval. Referenced by SetInterval(). |
|
Definition at line 322 of file CTimedEvent.h. References m_nCountDown. |
|
The interval is set to a new value.. This implies a reset.
Definition at line 361 of file CTimedEvent.cpp. References m_nMsInterval, and Reset(). Referenced by CExperiment::Start(). |
|
Execute a clock tick. The m_nCountDown is decremented. If <= 0, operator() is called and the countdown is reset.
Definition at line 344 of file CTimedEvent.cpp. References m_nCountDown, m_nMsInterval, and operator()(). |
|
Number of milliseconds until next event fire.
Definition at line 294 of file CTimedEvent.h. Referenced by getCountDown(), operator=(), operator==(), Reset(), setCountdown(), and Tick(). |
|
Number of milliseconds between events.
Definition at line 293 of file CTimedEvent.h. Referenced by getMsInterval(), operator=(), operator==(), Reset(), SetInterval(), and Tick(). |