CS::Threading::MutexImpl< BaseMutex > Class Template Reference
General mutex class. More...
#include <csutil/threading/mutex.h>
Inheritance diagram for CS::Threading::MutexImpl< BaseMutex >:
Public Member Functions | |
bool | Lock () |
Acquire lock on mutex. | |
MutexImpl () | |
Initialize an initially unlocked mutex. | |
bool | TryLock () |
Try to acquire lock on mutex. | |
void | Unlock () |
Unlock the mutex. | |
~MutexImpl () | |
Destroy mutex. |
Detailed Description
template<typename BaseMutex>
class CS::Threading::MutexImpl< BaseMutex >
General mutex class.
A mutex is a mutual exclusion object, it stops two threads from having it locked at the same time. A thread can get the lock by calling Lock or TryLock, and release it by calling Unlock.
Users are advised to use the ScopedLock helper class.
Definition at line 55 of file mutex.h.
Constructor & Destructor Documentation
template<typename BaseMutex>
CS::Threading::MutexImpl< BaseMutex >::MutexImpl | ( | ) | [inline] |
template<typename BaseMutex>
CS::Threading::MutexImpl< BaseMutex >::~MutexImpl | ( | ) | [inline] |
Member Function Documentation
template<typename BaseMutex>
bool CS::Threading::MutexImpl< BaseMutex >::Lock | ( | ) | [inline] |
template<typename BaseMutex>
bool CS::Threading::MutexImpl< BaseMutex >::TryLock | ( | ) | [inline] |
template<typename BaseMutex>
void CS::Threading::MutexImpl< BaseMutex >::Unlock | ( | ) | [inline] |
The documentation for this class was generated from the following file:
- csutil/threading/mutex.h
Generated for Crystal Space 2.0 by doxygen 1.6.1