| 57 | */ |
| 58 | template <typename T = DefaultResolution> |
| 59 | double stop() |
| 60 | { |
| 61 | if (!running) |
| 62 | { |
| 63 | return 0; |
| 64 | } |
| 65 | |
| 66 | running = false; |
| 67 | lapping = false; |
| 68 | auto duration = std::chrono::duration<double, T>(Clock::now() - start_time); |
| 69 | start_time = Clock::now(); |
| 70 | lap_time = Clock::now(); |
| 71 | |
| 72 | return duration.count(); |
| 73 | } |
| 74 | |
| 75 | /** |
| 76 | * @brief Calculates the time difference between now and when the timer was started |
no outgoing calls
no test coverage detected