#include <TimerManager.h>
Public Member Functions | |
TimerManager () | |
virtual | ~TimerManager () |
Object * | clone () const |
bool | unitTest () |
JString | createTimer (JString strData, long ms) |
Create a String Timer without callback. | |
JString | createTimer (Object *obj, long ms) |
Create an Object Timer without callback. | |
JString | createTimer (JString strData, long ms, void(*function)(JString id)) |
Create a String Timer with a function callback. | |
JString | createTimer (Object *obj, long ms, void(*function)(Object *object)) |
Create an Object Timer with a function callback. | |
JString | createTimer (JString strData, long ms, TimerReceiver *receiver) |
Create a String Timer with a TimerReceiver callback. | |
JString | createTimer (Object *obj, long ms, TimerObjectReceiver *receiver) |
Create an Object Timer with a TimerObjectReceiver callback. | |
void | doMaintenance () |
bool | cancel (JString id) |
Cancel Timer. | |
bool | cancelAll () |
Cancel all Timers. | |
long | waitFor (JString id) |
Wait for Timer. | |
long | msLeft (JString id) |
How long left of Timer. | |
int | getActiveTimerCount () |
Active Timer count. | |
Collection | getActiveTimerIDs () |
Get the active Timer IDs. | |
bool | receiveTimerObject (Object *obj) |
For testing only. | |
Protected Member Functions | |
Timer * | getTimer (JString id) |
Protected Attributes | |
ObjectDictionary * | timerList |
Definition at line 41 of file TimerManager.h.
cmlabs::TimerManager::TimerManager | ( | ) |
Definition at line 33 of file TimerManager.cpp.
cmlabs::TimerManager::~TimerManager | ( | ) | [virtual] |
Definition at line 39 of file TimerManager.cpp.
Object* cmlabs::TimerManager::clone | ( | ) | const [virtual] |
bool cmlabs::TimerManager::unitTest | ( | ) | [virtual] |
JString cmlabs::TimerManager::createTimer | ( | JString | strData, | |
long | ms, | |||
TimerReceiver * | receiver | |||
) |
Create a String Timer with a TimerReceiver callback.
Definition at line 92 of file TimerManager.cpp.
JString cmlabs::TimerManager::createTimer | ( | Object * | obj, | |
long | ms, | |||
TimerObjectReceiver * | receiver | |||
) |
Create an Object Timer with a TimerObjectReceiver callback.
Definition at line 103 of file TimerManager.cpp.
void cmlabs::TimerManager::doMaintenance | ( | ) |
Definition at line 114 of file TimerManager.cpp.
bool cmlabs::TimerManager::cancel | ( | JString | id | ) |
bool cmlabs::TimerManager::cancelAll | ( | ) |
long cmlabs::TimerManager::waitFor | ( | JString | id | ) |
long cmlabs::TimerManager::msLeft | ( | JString | id | ) |
int cmlabs::TimerManager::getActiveTimerCount | ( | ) |
Collection cmlabs::TimerManager::getActiveTimerIDs | ( | ) |
bool cmlabs::TimerManager::receiveTimerObject | ( | Object * | obj | ) | [virtual] |
For testing only.
Implements cmlabs::TimerObjectReceiver.
Definition at line 401 of file TimerManager.cpp.
Definition at line 211 of file TimerManager.cpp.
ObjectDictionary* cmlabs::TimerManager::timerList [protected] |
Definition at line 85 of file TimerManager.h.