![]() |
VSM C++ SDK
Vehicle Specific Modules SDK
|
Represents timer instance. More...
#include <timer_processor.h>
Public Types | |
typedef std::shared_ptr< Timer > | Ptr |
Pointer type. | |
typedef std::weak_ptr< Timer > | Weak_ptr |
Pointer type. | |
Public Member Functions | |
Timer (const Timer_processor::Ptr &processor, std::chrono::milliseconds interval) | |
Construct timer instance associated with a processor. More... | |
void | Cancel () |
Cancel running timer. More... | |
bool | Is_running () const |
Check if the timer still is running - i.e. More... | |
std::chrono::steady_clock::time_point | Get_fire_time () const |
Get time of next timer firing. More... | |
Static Public Member Functions | |
template<typename... Args> | |
static Ptr | Create (Args &&...args) |
Create an instance. More... | |
Friends | |
class | Timer_processor |
Represents timer instance.
ugcs::vsm::Timer_processor::Timer::Timer | ( | const Timer_processor::Ptr & | processor, |
std::chrono::milliseconds | interval | ||
) |
Construct timer instance associated with a processor.
void ugcs::vsm::Timer_processor::Timer::Cancel | ( | ) |
Cancel running timer.
Do nothing if timer is not running.
|
inlinestatic |
Create an instance.
|
inline |
Get time of next timer firing.
bool ugcs::vsm::Timer_processor::Timer::Is_running | ( | ) | const |
Check if the timer still is running - i.e.
will produce handler invocations.