类模板
<chrono>

std::chrono::time_point

template <class Clock, class Duration = typename Clock::duration>  class time_point;
Time point
A time_point object expresses a point in time relative to a clock's epoch.

Internally, the object stores an object of a duration type, and uses the Clock type as a reference for its epoch.

模板参数

Clock
A clock class, such as system_clock, steady_clock, high_resolution_clock or a custom clock class.
Duration
A duration type.

成员类型

以下别名是time_point的成员类型。它们被成员函数广泛用作参数和返回类型。

成员类型定义说明
clock第一个模板参数 (Clock)The clock class (either system_clock, steady_clock, high_resolution_clock or a custom clock class).
duration第二个模板参数 (Duration)The duration type used to represent the time point.
repduration::repType returned by duration::count.
periodduration::periodThe ratio type that represents the length of a period in seconds.

成员函数


静态成员函数


非成员函数


另见