alternative Standard Libary  0.29.8
std::mutex Klassenreferenz

#include <mutex.hpp>

+ Klassendiagramm für std::mutex:
+ Zusammengehörigkeiten von std::mutex:

Öffentliche Typen

using native_handle_type = Sys::mutex_type *
 

Öffentliche Methoden

 mutex (Sys::mutex_init_t type=Sys::mutex_init_t::Default, bool shared=false, bool robust=false)
 
virtual ~mutex ()
 
void lock (void)
 abstract function lock the current context Mehr ...
 
bool try_lock (void)
 abstract function try to lock the current context Mehr ...
 
void unlock (void)
 abstract function unlock the current locked context Mehr ...
 
native_handle_type native_handle ()
 
mutexoperator= (const mutex &m)
 
 mutex (const mutex &m)
 

Ausführliche Beschreibung

Dokumentation der benutzerdefinierten Datentypen

◆ native_handle_type

Beschreibung der Konstruktoren und Destruktoren

◆ mutex() [1/2]

std::mutex::mutex ( Sys::mutex_init_t  type = Sys::mutex_init_t::Default,
bool  shared = false,
bool  robust = false 
)
34  {
35  Sys::mutexInit(_m_locked, type, shared, robust);
36  }
static int mutexInit(mutex_type *mutex, mutex_init_t type=mutex_init_t::Normal, bool shared=false, bool robust=false)
Definition: PLATFORM.cpp:121

◆ ~mutex()

std::mutex::~mutex ( )
virtual
38  {
39  unlock();
40  Sys::mutexDestroy( _m_locked );
41  delete _m_locked;
42  }
void unlock(void)
abstract function unlock the current locked context
Definition: mutex.cpp:47
static int mutexDestroy(mutex_type *mutex)
Definition: PLATFORM.cpp:141

◆ mutex() [2/2]

std::mutex::mutex ( const mutex m)
63  {
64  _m_locked = m._m_locked;
65  }

Dokumentation der Elementfunktionen

◆ lock()

void std::mutex::lock ( void  )
virtual

abstract function lock the current context

Implementiert std::lock_base.

44  {
45  Sys::mutexLock( _m_locked );
46  }
static int mutexLock(mutex_type *mutex)
Definition: PLATFORM.cpp:144

◆ native_handle()

mutex::native_handle_type std::mutex::native_handle ( )
56  {
57  return _m_locked;
58  }

◆ operator=()

mutex & std::mutex::operator= ( const mutex m)
59  {
60  _m_locked = m._m_locked;
61  return *this;
62  }

◆ try_lock()

bool std::mutex::try_lock ( void  )
virtual

abstract function try to lock the current context

Implementiert std::lock_base.

52  {
53  return Sys::mutexTryLock( _m_locked ) == 0;
54  }
static int mutexTryLock(mutex_type *mutex)
Definition: PLATFORM.cpp:150

◆ unlock()

void std::mutex::unlock ( void  )
virtual

abstract function unlock the current locked context

Implementiert std::lock_base.

48  {
49  Sys::mutexUnLock( _m_locked );
50  }
static int mutexUnLock(mutex_type *mutex)
Definition: PLATFORM.cpp:147

Die Dokumentation für diese Klasse wurde erzeugt aufgrund der Dateien: