|
|
lucid
0.0.1
Lifting-based Uncertain Control Invariant Dynamics
|
Simple timer class to evaluate the performance of the software. More...
#include <Timer.h>
Public Member Functions | |
| TimerBase () | |
| Construct a new TimerBase object. | |
| void | start () |
| Start the timer. | |
| void | pause () |
| Pause the timer. | |
| void | resume () |
| Resume the timer. | |
| bool | is_running () const |
| Check whether the timer is running. | |
| duration | elapsed () const |
| Get read-only access to the duration of elapsed time of the timer. | |
| std::chrono::duration< double >::rep | seconds () const |
| Get read-only access to the number elapsed seconds of the timer. | |
Protected Member Functions | |
| time_point | now () const |
| Get read-only access to the current instant of the timer. | |
Simple timer class to evaluate the performance of the software.
The timer can be started, paused, and resumed. The elapsed time is returned in seconds or as a duration.
|
nodiscard |
Get read-only access to the duration of elapsed time of the timer.
|
nodiscard |
Check whether the timer is running.
|
inlinenodiscardprotected |
Get read-only access to the current instant of the timer.
| void lucid::TimerBase< T >::pause | ( | ) |
Pause the timer.
If the timer is not running, this function does nothing.
| void lucid::TimerBase< T >::resume | ( | ) |
Resume the timer.
If the timer is not running, this function does nothing.
|
nodiscard |
Get read-only access to the number elapsed seconds of the timer.
| void lucid::TimerBase< T >::start | ( | ) |
Start the timer.
The timer is reset to zero.