Abstract base class for timing utility.
#include <drake/common/timer.h>
Public Member Functions | |
Timer ()=default | |
Properly implemented Timers must start timing upon construction. More... | |
virtual | ~Timer () |
virtual void | Start ()=0 |
Begins timing. Call Start every time you want to reset the timer to zero. More... | |
virtual double | Tick ()=0 |
Obtains a timer measurement in seconds. More... | |
Protected Member Functions | |
Implements CopyConstructible, CopyAssignable, MoveConstructible, MoveAssignable | |
Timer (const Timer &)=default | |
Timer & | operator= (const Timer &)=default |
Timer (Timer &&)=default | |
Timer & | operator= (Timer &&)=default |
|
default |
Properly implemented Timers must start timing upon construction.
|
virtual |
|
pure virtual |
Begins timing. Call Start every time you want to reset the timer to zero.
Implemented in ManualTimer, and SteadyTimer.
|
pure virtual |
Obtains a timer measurement in seconds.
Call this repeatedly to get multiple measurements.
Implemented in ManualTimer, and SteadyTimer.