libstdc++
std::thread Class Reference

Classes

class  id
 

Public Types

using _State_ptr = unique_ptr< _State >
 
typedef __gthread_t native_handle_type
 

Public Member Functions

template<typename _Callable , typename... _Args, typename = _Require<__not_same<_Callable>>>
 thread (_Callable &&__f, _Args &&... __args)
 
 thread (const thread &)=delete
 
 thread (thread &&__t) noexcept
 
void detach ()
 
thread::id get_id () const noexcept
 
void join ()
 
bool joinable () const noexcept
 
native_handle_type native_handle ()
 
threadoperator= (const thread &)=delete
 
threadoperator= (thread &&__t) noexcept
 
void swap (thread &__t) noexcept
 

Static Public Member Functions

template<typename _Callable , typename... _Args>
static _Invoker< __decayed_tuple< _Callable, _Args... > > __make_invoker (_Callable &&__callable, _Args &&... __args)
 
static unsigned int hardware_concurrency () noexcept
 

Detailed Description

thread

Definition at line 62 of file thread.

Member Typedef Documentation

◆ _State_ptr

Definition at line 72 of file thread.

◆ native_handle_type

typedef __gthread_t std::thread::native_handle_type

Definition at line 74 of file thread.

Constructor & Destructor Documentation

◆ thread() [1/2]

template<typename _Callable , typename... _Args, typename = _Require<__not_same<_Callable>>>
std::thread::thread ( _Callable &&  __f,
_Args &&...  __args 
)
inlineexplicit

Definition at line 117 of file thread.

◆ ~thread()

std::thread::~thread ( )
inline

Definition at line 136 of file thread.

◆ thread() [2/2]

std::thread::thread ( thread &&  __t)
inlinenoexcept

Definition at line 144 of file thread.

Member Function Documentation

◆ __make_invoker()

template<typename _Callable , typename... _Args>
static _Invoker< __decayed_tuple< _Callable, _Args... > > std::thread::__make_invoker ( _Callable &&  __callable,
_Args &&...  __args 
)
inlinestatic

Definition at line 263 of file thread.

◆ get_id()

thread::id std::thread::get_id ( ) const
inlinenoexcept

Definition at line 172 of file thread.

◆ joinable()

bool std::thread::joinable ( ) const
inlinenoexcept

Definition at line 162 of file thread.

◆ native_handle()

native_handle_type std::thread::native_handle ( )
inline
Precondition
thread is joinable

Definition at line 178 of file thread.

◆ operator=()

thread & std::thread::operator= ( thread &&  __t)
inlinenoexcept

Definition at line 149 of file thread.

◆ swap()

void std::thread::swap ( thread __t)
inlinenoexcept

Definition at line 158 of file thread.


The documentation for this class was generated from the following file: