diff options
author | chatty | 1995-03-13 15:03:32 +0000 |
---|---|---|
committer | chatty | 1995-03-13 15:03:32 +0000 |
commit | e63a37896804d4c483512f460931793a5188ee1c (patch) | |
tree | 7cf33d469f0e64e6955005fa714cda378f07bea3 | |
parent | eb72b881a53340e6f6844bb081d2bc82aff40f8d (diff) | |
download | ivy-league-e63a37896804d4c483512f460931793a5188ee1c.zip ivy-league-e63a37896804d4c483512f460931793a5188ee1c.tar.gz ivy-league-e63a37896804d4c483512f460931793a5188ee1c.tar.bz2 ivy-league-e63a37896804d4c483512f460931793a5188ee1c.tar.xz |
Added TimerSet::IsEmpty, and Timer::SetHandler
-rw-r--r-- | utils/Timer.h | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/utils/Timer.h b/utils/Timer.h index c0d8ffc..733a443 100644 --- a/utils/Timer.h +++ b/utils/Timer.h @@ -3,7 +3,7 @@ * * by Stephane Chatty * - * Copyright 1992-1993 + * Copyright 1992-1995 * Centre d'Etudes de la Navigation Aerienne (CENA) * * timers @@ -21,6 +21,7 @@ #include "cplus_bugs.h" +#include "bool.h" #include "Time.h" class CcuSignalHandler; @@ -46,6 +47,7 @@ private: public: inline CcuTimerSet () : FirstTimer (0), OtherTimers () {} inline ~CcuTimerSet () {} +inline bool IsEmpty () const { return bool (FirstTimer == 0); } }; @@ -108,6 +110,8 @@ public: ~CcuBaseTimer (); }; +typedef void (*CcuTimerFun) (Millisecond); + class CcuTimer : public CcuBaseTimer { protected: void (*Handler) (Millisecond); @@ -116,7 +120,7 @@ protected: public: CcuTimer (Millisecond, void (*) (Millisecond), int = -1); ~CcuTimer (); +inline void SetHandler (void (*h) (Millisecond)) { Handler = h; } }; #endif /* Timer_H_ */ - |