21 #ifndef G_FUTURE_EVENT__H
22 #define G_FUTURE_EVENT__H
32 class FutureEventHandler ;
33 class FutureEventImp ;
65 G_EXCEPTION( Error ,
"FutureEvent error" ) ;
66 typedef HWND handle_type ;
74 handle_type
handle()
const ;
78 static bool send( handle_type handle ,
unsigned int payload ) g__noexcept ;
89 unique_ptr<FutureEventImp> m_imp ;
A callback interface for GNet::FutureEvent.
An abstract interface for handling exceptions thrown out of event-loop callbacks (socket events and t...
An object that hooks into the event loop and calls back to the client code with a small unsigned inte...
handle_type handle() const
Returns a handle that can be passed between threads and used in send().
~FutureEvent()
Destructor.
virtual void onFutureEvent(unsigned int)=0
Callback function that delivers the payload value from FutureEvent::send().
FutureEvent(FutureEventHandler &)
Constructor.
virtual ~FutureEventHandler()
Destructor.
A pimple-pattern implementation class used by GNet::FutureEvent.
static bool send(handle_type handle, unsigned int payload) g__noexcept
Pokes the event payload into the main event loop so that the callback is called once the stack is unw...