Merge pull request #2309 from mitza-oci/warnings
[ACE_TAO.git] / ACE / examples / APG / Timers / PTimerDispatcher.h
blob12c3ccabe03452758f537e281fd0be920780346a
1 /* -*- C++ -*- */
2 #if !defined(PTIMER_DISPATCHER_H)
3 #define PTIMER_DISPATCHER_H
5 #include "ace/Singleton.h"
6 #include "ace/Synch.h" // needed for ACE_Event
8 #include "Upcall.h"
9 class PCB;
11 class PTimer_Dispatcher
13 public:
14 void wait_for_event ();
16 long schedule (PCB *cb,
17 void *arg,
18 const ACE_Time_Value &abs_time,
19 const ACE_Time_Value &interval);
21 int cancel (PCB *cb,
22 int dont_call_handle_close = 1);
24 int reset_interval (long timer_id,
25 const ACE_Time_Value &interval);
27 void set (PTimerQueue *timer_queue);
29 private:
30 PTimerQueue *timer_queue_;
31 ACE_Event timer_;
34 typedef ACE_Singleton<PTimer_Dispatcher, ACE_Null_Mutex> PTimer;
36 #endif /*TIMER_DISPATCHER_H*/