Helper to count the seconds of a duration/time_point.
Declared in <util/time.h>
template<
typename Dur1,
typename Dur2>
constexpr
auto
Ticks(Dur2 d);
All durations/time_points should be using std::chrono and calling this should generally be avoided in code. Though, it is still preferred to an inline t.count() to protect against a reliance on the exact type of t.
This helper is used to convert durations/time_points before passing them over an interface that doesn't support std::chrono (e.g. RPC, debug log, or the GUI)
The tick count of d expressed in the Dur1 units.
| Name | Description |
|---|---|
| d | Duration to convert. |