#include <CBufferEvent.h>
Inheritance diagram for CBufferEvent< T >:
Public Member Functions | |
CBufferEvent () | |
Anonymous buffer event. | |
CBufferEvent (const char *pName) | |
Named event with char* name. | |
CBufferEvent (const STD(string)&rName) | |
Named event with STD(string) name. | |
~CBufferEvent () | |
Destroy the event. | |
STD (list)< AddLinkRequest > getPendingAddQueue() const | |
STD (list)< AddLinkRequest > getPendingDeleteQueue() const | |
CBufferMonitor< T > & | getMonitor () |
Allow manipulation of the event monitor:. | |
CBufferReactor< T > & | getReactor () |
Allow manipulation of the event reactor:. | |
void | AddLink (const STD(string)&url, unsigned int tag, unsigned int mask=ALLBITS_MASK, int reliability=COS_RELIABLE) |
void | DeleteLink (const STD(string)&url, unsigned int tag, unsigned int mask=ALLBITS_MASK, int reliability=COS_RELIABLE) |
virtual void | OnBuffer (Pointer< DAQBuffer< T >, T > &pBuffer) |
virtual void | OnTimeout () |
virtual void | setBufferTag (int tag) |
virtual void | setBufferMask (int mask) |
virtual | STD (string) DescribeSelf() |
Protected Member Functions | |
virtual void | ProcessQueues () |
void | ProcessAddQueue () |
void | ProcessDelQueue () |
STD (string) QueueEntryToString(AddLinkRequest &rEntry) | |
Private Member Functions | |
STD (list)< AddLinkRequest > m_AddQueue | |
Requests to add links go here. | |
STD (list)< AddLinkRequest > m_DelQueue | |
Requests to delete links go here. | |
CBufferEvent (const CBufferEvent &rhs) | |
CBufferEvent & | operator= (const CBufferEvent &rhs) |
int | operator== (const CBufferEvent &rhs) |
Private Attributes | |
CBufferMonitor< T > & | m_rMonitor |
Monitors the input links. | |
CGenericBufferReactor< T > & | m_rReactor |
Reacts to the input links. |
|
Anonymous buffer event. Construct an anonymous event. The monitor is a standard buffer monitor, the event readctor is a CGenericBufferReactor. Definition at line 366 of file CBufferEvent.cpp. References CBufferEvent< T >::getMonitor(), CBufferEvent< T >::getReactor(), CBufferEvent< T >::m_rMonitor, and CBufferEvent< T >::m_rReactor. |
|
Named event with char* name. Called to create a named buffer event when the name is a char* string: Definition at line 378 of file CBufferEvent.cpp. |
|
Named event with STD(string) name.
|
|
Destroy the event. Destroy the buffer event: Definition at line 402 of file CBufferEvent.cpp. |
|
|
|
|
|
|
|
Allow manipulation of the event monitor:.
Reimplemented from CEvent. Definition at line 420 of file CBufferEvent.h. Referenced by CBufferEvent< T >::CBufferEvent(). |
|
Allow manipulation of the event reactor:.
Reimplemented from CEvent. Definition at line 423 of file CBufferEvent.h. Referenced by CBufferEvent< T >::CBufferEvent(). |
|
This member function is the default (no-op) action when a buffer has been received on the link.
Definition at line 484 of file CBufferEvent.cpp. Referenced by CBufferEvent< T >::CGenericBufferReactor< U >::OnBuffer(). |
|
This member function is the default (no-op) action when waiting for buffers has timed out and timeout delivery is enabled. Definition at line 494 of file CBufferEvent.cpp. Referenced by CBufferEvent< T >::CGenericBufferReactor< U >::OnTimeout(). |
|
|
|
|
|
This utility function is called to take all of the elements in the Add queue and create links corresponding to them. It should be called only in the context of the executing event thread. Definition at line 522 of file CBufferEvent.cpp. References CApplicationSerializer::getInstance(), CThreadRecursiveMutex::Lock(), CBufferEvent< T >::m_rMonitor, CBufferEvent< T >::AddLinkRequest::s_linktype, CBufferEvent< T >::AddLinkRequest::s_mask, CBufferEvent< T >::AddLinkRequest::s_tag, and CThreadRecursiveMutex::UnLock(). Referenced by CBufferEvent< T >::ProcessQueues(). |
|
This utility function is called periodically in the context of the event thread. It dequeues each element from the delete link request queue and deletes the corresponding link. Definition at line 542 of file CBufferEvent.cpp. References CApplicationSerializer::getInstance(), LinkIterator, CThreadRecursiveMutex::Lock(), CBufferEvent< T >::m_rMonitor, CBufferEvent< T >::AddLinkRequest::s_mask, CBufferEvent< T >::AddLinkRequest::s_tag, and CThreadRecursiveMutex::UnLock(). Referenced by CBufferEvent< T >::ProcessQueues(). |
|
Called periodically at event thread context to process any ITC's (inter thread communication) primitives which are required by the event. In this case, we need to process the two link request queues:
since context switches are in theory unpredictable, it's possible to queue a deletion on an add request which has not yet been processed. Therefore, the add queue is processed first and then the delete queue. Reimplemented from CEvent. Definition at line 510 of file CBufferEvent.cpp. References CBufferEvent< T >::ProcessAddQueue(), and CBufferEvent< T >::ProcessDelQueue(). |
|
Definition at line 442 of file CBufferEvent.h. |
|
Definition at line 439 of file CBufferEvent.h. |
|
The name of the object Reimplemented from CEvent. |
|
The name of the object Reimplemented from CEvent. |
|
Definition at line 414 of file CBufferEvent.h. |
|
Definition at line 408 of file CBufferEvent.h. |
|
Requests to delete links go here.
|
|
Requests to add links go here.
Referenced by CBufferEvent< U >::STD(). |
|
Monitors the input links.
Reimplemented from CEvent. Definition at line 386 of file CBufferEvent.h. Referenced by CBufferEvent< T >::CBufferEvent(), CBufferEvent< T >::ProcessAddQueue(), and CBufferEvent< T >::ProcessDelQueue(). |
|
Reacts to the input links.
Reimplemented from CEvent. Definition at line 387 of file CBufferEvent.h. Referenced by CBufferEvent< T >::CBufferEvent(). |