名前空間
変種

operator==,!=,<,<=,>,>=,<=>(std::thread::id)

提供: cppreference.com
 
 
スレッドサポートライブラリ
スレッド
(C++11)
(C++20)
(C++20)
this_thread 名前空間
(C++11)
(C++11)
(C++11)
相互排他
(C++11)
汎用ロック管理
(C++11)
(C++11)
(C++11)
(C++11)(C++11)(C++11)
(C++11)
(C++11)
条件変数
(C++11)
セマフォ
ラッチとバリア
(C++20)
(C++20)
フューチャー
(C++11)
(C++11)
(C++11)
(C++11)
 
 
std::thread::id
メンバ関数
非メンバ関数
(C++20未満)(C++20未満)(C++20未満)(C++20未満)(C++20未満)(C++20)
ヘルパークラス
 
<tbody> </tbody>
bool operator==( thread::id lhs, thread::id rhs ) noexcept;
(1) (C++11以上)
bool operator!=( thread::id lhs, thread::id rhs ) noexcept;
(2) (C++11以上)
(C++20未満)
bool operator<( thread::id lhs, thread::id rhs ) noexcept;
(3) (C++11以上)
(C++20未満)
bool operator<=( thread::id lhs, thread::id rhs ) noexcept;
(4) (C++11以上)
(C++20未満)
bool operator>( thread::id lhs, thread::id rhs ) noexcept;
(5) (C++11以上)
(C++20未満)
bool operator>=( thread::id lhs, thread::id rhs ) noexcept;
(6) (C++11以上)
(C++20未満)
std::strong_ordering operator<=>( thread::id lhs, thread::id rhs ) noexcept;
(7) (C++20以上)

2つのスレッド識別子を比較します。

1-2) lhsrhs が同じスレッドを表す (またはどちらもスレッドを表さない) かどうか調べます。
3-7) 未規定の全順序で lhsrhs を比較します。

引数

lhs, rhs - 比較するスレッド識別子

戻り値

1-6) 対応する関係が成立する場合は true、そうでなければ false
7) 全順序で lhsrhs より小さければ std::strong_ordering::less、そうでなく rhslhs より小さければ std::strong_ordering::greater、そうでなければ std::strong_ordering::equal

計算量

定数。

関連項目

Morty Proxy This is a proxified and sanitized view of the page, visit original site.