Namespaces
Variants

std::condition_variable:: native_handle

From cppreference.net

Concurrency support library
Threads
(C++11)
(C++20)
this_thread namespace
(C++11)
(C++11)
Cooperative cancellation
Mutual exclusion
Generic lock management
Condition variables
(C++11)
Semaphores
Latches and Barriers
(C++20)
(C++20)
Futures
(C++11)
(C++11)
(C++11)
Safe reclamation
Hazard pointers
Atomic types
(C++11)
(C++20)
Initialization of atomic types
(C++11) (deprecated in C++20)
(C++11) (deprecated in C++20)
Memory ordering
(C++11) (deprecated in C++26)
Free functions for atomic operations
Free functions for atomic flags
native_handle_type native_handle ( ) ;
(自 C++11 起)

访问 * this 的原生句柄。

此函数返回结果的含义和类型由实现定义。在 POSIX 系统中,该值可能为 pthread_cond_t * 类型。在 Windows 系统中,该值可能为 PCONDITION_VARIABLE 类型。

参数

(无)

返回值

此条件变量的原生句柄。

另请参阅

返回底层实现定义的线程句柄
( std::thread 的公开成员函数)
返回底层实现定义的线程句柄
( std::jthread 的公开成员函数)