|
LRAUV
revA
|
An implementation of RAII for the Mutex. More...
#include <Mutex.h>

Public Member Functions | |
| MutexLocker (Mutex &mutex) | |
| Constructor "creates" a lock on the mutex. More... | |
| ~MutexLocker () | |
| Destructor "destroys" the lock on the mutex. More... | |
Private Attributes | |
| Mutex & | mutex_ |
| Reference to keep track of the Mutex. More... | |
An implementation of RAII for the Mutex.
| MutexLocker::MutexLocker | ( | Mutex & | mutex | ) |
Constructor "creates" a lock on the mutex.
References Mutex::lock(), and mutex_.
| MutexLocker::~MutexLocker | ( | ) |
Destructor "destroys" the lock on the mutex.
References mutex_, and Mutex::unlock().
|
private |
Reference to keep track of the Mutex.
Referenced by MutexLocker(), and ~MutexLocker().