BoB robotics
The Brains on Board robotics library
BoBRobotics::Stopwatch Class Reference

Public Types

using TimePoint = std::chrono::high_resolution_clock::time_point
 
using Duration = std::chrono::high_resolution_clock::duration
 

Public Member Functions

void start ()
 Start measuring elapsed time from now.
 
bool started () const
 Check if stopwatch has been started.
 
void reset ()
 Reset stopwatch to zero.
 
Duration elapsed () const
 Returns elapsed time since start() was called.
 
Duration lap ()
 Returns the current elapsed time and restarts the Stopwatch.
 

Static Public Member Functions

static TimePoint now ()
 Get the current time.
 

The documentation for this class was generated from the following files: