Celeritas  0.5.0-56+6b053cd
Public Member Functions | List of all members
celeritas::Stopwatch Class Reference

Simple timer. More...

#include <Stopwatch.hh>

Public Member Functions

 Stopwatch ()
 Start the count at construction.
 
double operator() () const
 Get the current elapsed time in seconds.
 

Detailed Description

Simple timer.

The stopwatch starts counting upward at construction and can be reset by assigning a new stopwatch instance.

Stopwatch get_elapsed_time;
// ...
double time = get_elapsed_time();
// Reset the stopwatch
get_elapsed_time = {};
Stopwatch()
Start the count at construction.
Definition: Stopwatch.hh:54

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