21 : start_(std::chrono::high_resolution_clock::now()),
22 end_(std::chrono::high_resolution_clock::now()) {}
24 void reset() { start_ = std::chrono::high_resolution_clock::now(); }
26 void stop() { end_ = std::chrono::high_resolution_clock::now(); }
29 auto timeSpan = std::chrono::duration_cast<std::chrono::duration<double>>(
31 return timeSpan.count();
35 std::chrono::high_resolution_clock::time_point start_;
36 std::chrono::high_resolution_clock::time_point end_;
void reset()
Definition: timer.hpp:24
Timer()
Definition: timer.hpp:20
class for counting time (microsecond)
Definition: timer.hpp:18
void stop()
Definition: timer.hpp:26
double elapsedSeconds() const
Definition: timer.hpp:28