libstdc++: std::mutex Class Reference (original) (raw)
#include <[mutex](a00146%5Fsource.html)>
Inherits __mutex_base.
Public Member Functions | |
---|---|
mutex (const mutex &)=delete | |
void | lock () |
native_handle_type | native_handle () noexcept |
mutex & | operator= (const mutex &)=delete |
bool | try_lock () noexcept |
void | unlock () |
Detailed Description
The standard mutex type.
A simple, non-recursive, non-timed mutex.
Do not call lock()
and unlock()
directly, use a scoped lock type such as std::unique_lock
, std::lock_guard
, or (since C++17) std::scoped_lock
.
Since
C++11
Definition at line 96 of file std_mutex.h.
Member Typedef Documentation
◆ native_handle_type
typedef __native_type* std::mutex::native_handle_type
Member Function Documentation
◆ lock()
void std::mutex::lock ( ) | inline |
---|
◆ native_handle()
native_handle_type std::mutex::native_handle ( ) | inlinenoexcept |
---|
◆ try_lock()
bool std::mutex::try_lock ( ) | inlinenoexcept |
---|
◆ unlock()
void std::mutex::unlock ( ) | inline |
---|
The documentation for this class was generated from the following file: