|
Time Shield Library
C++ library for working with time
|
Timer scheduler that provides Qt-like timer functionality. More...
Go to the source code of this file.
Classes | |
| struct | time_shield::detail::TimerState |
| Internal state shared between Timer and TimerScheduler. More... | |
| struct | time_shield::detail::RunningTimerScope |
| struct | time_shield::detail::ScheduledTimer |
| Data stored in the priority queue of scheduled timers. More... | |
| struct | time_shield::detail::ScheduledComparator |
| Comparator that orders timers by earliest fire time. More... | |
| struct | time_shield::detail::DueTimer |
| Helper structure that represents a timer ready to run. More... | |
| class | time_shield::TimerScheduler |
| Scheduler that manages timer execution. More... | |
| class | time_shield::Timer |
| Timer that mimics the behavior of Qt timers. More... | |
Namespaces | |
| namespace | time_shield |
| Main namespace for the Time Shield library. | |
| namespace | time_shield::detail |
Typedefs | |
| using | time_shield::detail::TimerClock = std::chrono::steady_clock |
| using | time_shield::detail::TimerCallback = std::function<void()> |
| using | time_shield::timer_state_ptr = std::shared_ptr<detail::TimerState> |
Functions | |
| TimerState *& | time_shield::detail::current_timer_state () |
Timer scheduler that provides Qt-like timer functionality.
TimerScheduler manages timers that can be processed either by a dedicated worker thread or manually via process/update calls. Timers are rescheduled using fixed-rate semantics, meaning the next activation time is based on the previously scheduled fire time. Cancelled timers are removed lazily from the internal queue, which can temporarily increase the queue size under frequent start/stop cycles.
Definition in file TimerScheduler.hpp.