std::chrono::utc_clock:: from_sys
|
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Member functions | ||||
|
utc_clock::from_sys
|
||||
| Time point I/O | ||||
| Leap second insertion information | ||||
|
template
<
class
Duration
>
static
std::
chrono
::
utc_time
<
std::
common_type_t
<
Duration,
std::
chrono
::
seconds
>>
|
(C++20 起) | |
将
sys_time
t
转换为表示同一时间点的
utc_time
u
。
u. time_since_epoch ( ) - t. time_since_epoch ( ) 等于在 t 与 1970年1月1日之间插入的闰秒数量。如果 t 恰好是闰秒插入的精确日期,则该闰秒计入已插入的闰秒数。
返回值
一个表示与
t
相同时间点的
utc_time
。
参见
|
[static]
|
将
utc_time
转换为
sys_time
(公开静态成员函数) |
|
(C++20)
|
将一种时钟的时间点转换为另一种时钟的时间点
(函数模板) |