diff options
author | harrison <harrison@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 1996-12-08 20:33:35 +0000 |
---|---|---|
committer | harrison <harrison@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 1996-12-08 20:33:35 +0000 |
commit | b2011698f5b9a63b5738edf5657e61822a225cb9 (patch) | |
tree | 093982ab4f89385ea0c527b3aef942b383f18d65 /ace | |
parent | 15924541e32170e78569ed9bb64aa7f68777e2a0 (diff) | |
download | ATCD-b2011698f5b9a63b5738edf5657e61822a225cb9.tar.gz |
Hi everyone!
Diffstat (limited to 'ace')
-rw-r--r-- | ace/Timer_Queue.h | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/ace/Timer_Queue.h b/ace/Timer_Queue.h index 90972f34598..86f97b43696 100644 --- a/ace/Timer_Queue.h +++ b/ace/Timer_Queue.h @@ -1,7 +1,6 @@ /* -*- C++ -*- */ // $Id$ - // ============================================================================ // // = LIBRARY @@ -78,6 +77,7 @@ public: // = Initialization and termination methods. ACE_Timer_Queue (void); // Default constructor. + virtual ~ACE_Timer_Queue (void); int is_empty (void) const; @@ -86,6 +86,10 @@ public: const ACE_Time_Value &earliest_time (void) const; // Returns the time of the earlier node in the Timer_Queue. + // = Set/get the timer skew for the Timer_Queue. + void timer_skew (const ACE_Time_Value &skew); + const ACE_Time_Value &timer_skew (void) const; + virtual int schedule (ACE_Event_Handler *event_handler, const void *arg, const ACE_Time_Value &delay, @@ -114,6 +118,10 @@ public: // argument passed in when the <Event_Handler> was registered. This // makes it possible to free up the memory and avoid memory leaks. + virtual int expire (void); + // Expires all pending timers whose values are <= + // ACE_OS::gettimeofday. Also accounts for timer_skew_. + virtual int expire (const ACE_Time_Value ¤t_time); // Run the <handle_timeout> method for all Timers whose values are // <= <cur_time>. @@ -143,12 +151,17 @@ private: // This id can be used to cancel a timer via the <cancel (int)> // method. + ACE_Time_Value timer_skew_; + // Adjusts for timer skew in various clocks. + #if defined (ACE_MT_SAFE) ACE_Recursive_Thread_Mutex lock_; // Synchronization variable for the MT_SAFE ACE_Reactor #endif /* ACE_MT_SAFE */ }; +#if defined (__ACE_INLINE__) #include "ace/Timer_Queue.i" +#endif /* __ACE_INLINE__ */ #endif /* ACE_TIMER_QUEUE_H */ |