std::chrono::system_clock::to_time_t

< cpp‎ | chrono‎ | system clock
static std::time_t to_time_t( const time_point& t ) noexcept;
(C++11 起)

转换 tstd::time_t 类型。

std::time_t 拥有较低精度,则是舍入还是截断值是实现定义的。

参数

t - 要转换的系统时钟时间点

返回值

表示 tstd::time_t 值。

参阅

[静态]
转换 std::time_t 到系统时钟时间点
(公开静态成员函数)