#include <CEventMonitor.h>
Inheritance diagram for CEventMonitor:
Public Types | |
enum | result { Occurred = 0, TimedOut = 1, Error = 2 } |
Public Member Functions | |
CEventMonitor (bool am_fTimedWait=true) | |
CEventMonitor (const STD(string)&rName, bool am_fTimedWait=true) | |
CEventMonitor (const char *pName, bool am_fTimedWait=true) | |
int | operator== (const CEventMonitor &aCEventMonitor) const |
virtual | ~CEventMonitor () |
timeval | getTimeout () const |
bool | getTimedWait () const |
virtual CEventMonitor::result | operator() ()=0 |
virtual void | setTimeout (int nTimeout=FOREVER) |
Protected Member Functions | |
void | setTimeout (const timeval am_tvTimeout) |
void | setTimedWait (const bool am_fTimedWait) |
Static Protected Member Functions | |
STD (string) GetAutoName(const STD(string)&rBaseName) | |
Private Member Functions | |
CEventMonitor (const CEventMonitor &aCEventMonitor) | |
Copy construction is forbidden for now. | |
CEventMonitor | operator= (const CRegisteredObject &aCEventMonitor) |
Assignment is forbidden for now. | |
Private Attributes | |
timeval | m_tvTimeout |
bool | m_fTimedWait |
Static Private Attributes | |
unsigned int | m_nAutoIndex |
Definition at line 328 of file CEventMonitor.h.
|
Used to name autonamed objects Definition at line 337 of file CEventMonitor.h. |
|
Default constructor. An EventMonitor with name of the form Monitor_nnn is created. The monitor is entered in to the "Monitors" registry of the classified object registry returned from getCClassifiedObjectRegistry(). The name used is gaurenteed unique and can be queried via: getName(). Definition at line 317 of file CEventMonitor.cpp. References CNamedObject::AppendClassInfo(), m_fTimedWait, m_tvTimeout, and RegistryName. |
|
|
|
Constructs an event monitor given its name as an ASCII string and an (optional) value for m_fTimedWait :
Definition at line 359 of file CEventMonitor.cpp. References CNamedObject::AppendClassInfo(), m_fTimedWait, m_tvTimeout, and RegistryName. |
|
Copy construction is forbidden for now.
|
|
Destructor: Just ensure that we are removed from the Reactors registry before being destroyed. Definition at line 373 of file CEventMonitor.cpp. References CRegisteredObject::getRegistry(), RegistryName, and CClassifiedObjectRegistry::Remove(). |
|
Definition at line 377 of file CEventMonitor.h. Referenced by CFdMonitor::operator()(), and CBufferMonitor< T >::operator()(). |
|
Definition at line 372 of file CEventMonitor.h. Referenced by CTimerMonitor::operator()(), CLocationMonitor< T >::operator()(), CFdMonitor::operator()(), and CBufferMonitor< T >::operator()(). |
|
Implemented in CBufferMonitor< T >, CFdMonitor, CLocationMonitor< T >, CServerMonitor, CTimerMonitor, and CBufferMonitor< U >. |
|
Assignment is forbidden for now.
Reimplemented from CRegisteredObject. Reimplemented in CFdMonitor. |
|
Definition at line 350 of file CEventMonitor.h. References m_fTimedWait, m_tvTimeout, and CRegisteredObject::operator==(). Referenced by CTimerMonitor::operator==(), CLocationMonitor< T >::operator==(), and CFdMonitor::operator==(). |
|
Definition at line 390 of file CEventMonitor.h. References m_fTimedWait. |
|
void CEventMonitor::setTimeout(int nTimeout=FOREVER) Operation Type: mutator Purpose: Sets the timeout. The length of the timeout is determined by the parameter in ms.. Special values: 0 - Poll (return instantly). FOREVER - Block until event. Reimplemented in CTimerMonitor. Definition at line 394 of file CEventMonitor.cpp. References m_fTimedWait, and m_tvTimeout. |
|
Definition at line 385 of file CEventMonitor.h. References m_tvTimeout. Referenced by CEvent::operator()(), and CTimerMonitor::setTimeout(). |
|
Reimplemented from CNamedObject. |
|
Timeout length Definition at line 331 of file CEventMonitor.h. Referenced by CEventMonitor(), operator==(), setTimedWait(), and setTimeout(). |
|
Timed wait? Reimplemented from CNamedObject. |
|
Definition at line 330 of file CEventMonitor.h. Referenced by CEventMonitor(), operator==(), and setTimeout(). |