zoned_time& operator=( const zoned_time& other ) = default; | (1) | (since C++20) |
zoned_time& operator=( const std::chrono::sys_time<Duration>& other ); | (2) | (since C++20) |
zoned_time& operator=( const std::chrono::local_time<Duration>& other ); | (3) | (since C++20) |
Assign the value of other
to *this
.
zoned_time
has no move assignment operator; a move is a copy.other
to the stored time point. The time zone pointer is unchanged. After this call, get_sys_time() == other
.other
to a std::chrono::sys_time
as if by zone->to_sys(other)
(where zone
is the non-static data member holding the stored time zone pointer) and assigns the result to the stored time point. The time zone pointer is unchanged. After this call, get_local_time() == other
.*this
.
© cppreference.com
Licensed under the Creative Commons Attribution-ShareAlike Unported License v3.0.
https://en.cppreference.com/w/cpp/chrono/zoned_time/operator%3D