std::stop_source::get_token
提供: cppreference.com
< cpp | thread | stop source
[[nodiscard]] std::stop_token get_token() const noexcept; |
(C++20以上) | |
stop_source
が停止状態を持つ場合は、その停止状態に紐付いた stop_token
オブジェクトを返します。 そうでなければ、デフォルト構築された (空の) stop_token
を返します。
[編集] 引数
(なし)
[編集] 戻り値
stop_token
オブジェクト (this->stop_possible() == false の場合は空です)。
[編集] 例
This section is incomplete Reason: no example |