C++ TargetRTS
|
An identifier for a timer request. More...
#include <RTTimerId.h>
Public Member Functions | |
RTTimerId (RTTimerNode *) | |
RTTimerId (const RTTimerId &) | |
RTTimerId & | operator= (const RTTimerId &) |
RTTimerId & | operator= (RTTimerNode *) |
int | operator== (const RTTimerId &) const |
int | operator!= (const RTTimerId &) const |
int | isValid (void) const |
Check if this object identifies a valid timer request. | |
int | timeouts (void) const |
Get the number of timeout intervals that passed before the timeout of a periodic timer was actually processed. | |
Static Public Attributes | |
static const RTObject_class | classData |
Type descriptor for an RTTimerId. | |
Friends | |
class | RTTimerNode |
An identifier for a timer request.
The functions in Timing::Base which start timers (Timing::Base::informIn(), Timing::Base::informAt() and Timing::Base::informEvery()) return an object of this class, and you can use that object to interact with the started timer (for example to cancel it).
int RTTimerId::isValid | ( | void | ) | const |
Check if this object identifies a valid timer request.
This function does not return the exact state of the timer. For example, it does not tell you if the timer is still active, or if the timer has already timed out but the timeout event has not yet been delivered; or if the timer has been canceled or a non-periodic timer has timed out. You should call this function before performing any operations on the timer, to ensure that it still is valid.
int RTTimerId::timeouts | ( | void | ) | const |
Get the number of timeout intervals that passed before the timeout of a periodic timer was actually processed.
Calling this function is a way to measure the accuracy of a periodic timer. For more information see Timing::Base::timeouts().