wibble
1.1
|
pthread mutex wrapper; WARNING: the class allows copying and assignment, but this is not always safe. More...
#include <mutex.h>
Public Member Functions | |
Mutex (bool recursive=false) | |
Mutex (const Mutex &) | |
~Mutex () | |
bool | trylock () |
void | lock () |
Lock the mutex Normally it's better to use MutexLock. More... | |
void | unlock () |
Unlock the mutex Normally it's better to use MutexLock. More... | |
void | reinit () |
Reinitialize the mutex. More... | |
Friends | |
class | Condition |
pthread mutex wrapper; WARNING: the class allows copying and assignment, but this is not always safe.
You should never copy a locked mutex. It is however safe to copy when there is no chance of any of the running threads using the mutex.
|
inline |
|
inline |
|
inline |
|
inline |
Lock the mutex Normally it's better to use MutexLock.
Referenced by wibble::sys::MutexLockT< Mutex >::MutexLockT(), and wibble::sys::MutexLockT< Mutex >::reclaim().
|
inline |
Reinitialize the mutex.
|
inline |
|
inline |
Unlock the mutex Normally it's better to use MutexLock.
Referenced by wibble::sys::MutexLockT< Mutex >::drop(), and wibble::sys::MutexLockT< Mutex >::~MutexLockT().
|
friend |