24 #ifndef __DOB_UTILITIES_ACE_DISPATCHER_H__
25 #define __DOB_UTILITIES_ACE_DISPATCHER_H__
27 #include <boost/noncopyable.hpp>
29 #include <Safir/Dob/Internal/Atomic.h>
32 #pragma warning (push)
33 #pragma warning (disable: 4127 4244 4251)
36 #include <ace/Reactor.h>
52 public ACE_Event_Handler,
53 private boost::noncopyable
63 ACE_Event_Handler(ACE_Reactor::instance()),
64 m_connection(connection),
75 ACE_Reactor * reactor):
76 ACE_Event_Handler(reactor),
77 m_connection(connection),
86 virtual int handle_exception(ACE_HANDLE)
97 virtual void OnDoDispatch()
99 if (m_isNotified == 0)
102 reactor()->notify(
this);
108 Safir::Dob::Internal::AtomicUint32 m_isNotified;
114 #endif // __DOB_UTILITIES_ACE_DISPATCHER_H__
Interface for reception of a dispatch order.
Definition: Consumer.h:72
The class makes a thread switch and perform a dispatch on Dob connection.
Definition: AceDispatcher.h:50
void Dispatch() const
When the dispatch event or callback is signalled, the application MUST call this method.
AceDispatcher(const Safir::Dob::Connection &connection)
Constructor.
Definition: AceDispatcher.h:62
A connection to the DOB.
Definition: Dob/Connection.h:45
AceDispatcher(const Safir::Dob::Connection &connection, ACE_Reactor *reactor)
Constructor.
Definition: AceDispatcher.h:74