operator==,!=,<,<=,>,>=,<=>(std::chrono::time_point)
| Definiert in Header <chrono> |
||
| (1) | ||
template< class Clock, class Dur1, class Dur2 > bool operator==( const std::chrono::time_point<Clock,Dur1>& lhs, |
(seit C++11) (bis C++14) |
|
| template< class Clock, class Dur1, class Dur2 > constexpr bool operator==( const std::chrono::time_point<Clock,Dur1>& lhs, |
(seit C++14) | |
| (2) | ||
template< class Clock, class Dur1, class Dur2 > bool operator!=( const std::chrono::time_point<Clock,Dur1>& lhs, |
(seit C++11) (bis C++14) |
|
| template< class Clock, class Dur1, class Dur2 > constexpr bool operator!=( const std::chrono::time_point<Clock,Dur1>& lhs, |
(seit C++14) (bis C++20) |
|
| (3) | ||
template< class Clock, class Dur1, class Dur2 > bool operator<( const std::chrono::time_point<Clock,Dur1>& lhs, |
(seit C++11) (bis C++14) |
|
| template< class Clock, class Dur1, class Dur2 > constexpr bool operator<( const std::chrono::time_point<Clock,Dur1>& lhs, |
(seit C++14) | |
| (4) | ||
template< class Clock, class Dur1, class Dur2 > bool operator<=( const std::chrono::time_point<Clock,Dur1>& lhs, |
(seit C++11) (bis C++14) |
|
| template< class Clock, class Dur1, class Dur2 > constexpr bool operator<=( const std::chrono::time_point<Clock,Dur1>& lhs, |
(seit C++14) | |
| (5) | ||
template< class Clock, class Dur1, class Dur2 > bool operator>( const std::chrono::time_point<Clock,Dur1>& lhs, |
(seit C++11) (bis C++14) |
|
| template< class Clock, class Dur1, class Dur2 > constexpr bool operator>( const std::chrono::time_point<Clock,Dur1>& lhs, |
(seit C++14) | |
| (6) | ||
template< class Clock, class Dur1, class Dur2 > bool operator>=( const std::chrono::time_point<Clock,Dur1>& lhs, |
(seit C++11) (bis C++14) |
|
| template< class Clock, class Dur1, class Dur2 > constexpr bool operator>=( const std::chrono::time_point<Clock,Dur1>& lhs, |
(seit C++14) | |
| template< class Clock, class Dur1, std::three_way_comparable_with<Dur1> Dur2 > constexpr auto operator<=>( const std::chrono::time_point<Clock,Dur1>& lhs, |
(7) | (seit C++20) |
Vergleicht zwei Zeitpunkte. Der Vergleich erfolgt durch den Vergleich der Ergebnisse von time_since_epoch() für die Zeitpunkte.
Dur1 und Dur2.|
Der Operator |
(seit C++20) |
Inhalt |
[bearbeiten] Parameter
| lhs, rhs | - | zu vergleichende Zeitpunkte |
[bearbeiten] Rückgabewert
[edit] Exceptions
Kann implementierungsdefinierte Ausnahmen auslösen.
[bearbeiten] Anmerkungen
Zwei-Wege-Vergleichsoperatoren von time_point waren in C++11 nicht constexpr. Dies wurde in C++14 korrigiert.