C3D Toolkit
Kernel - 117982, Vision - 2.9.2.2
|
MutexLocker class is a mutex wrapper that provides convenient ownership mechanism of mutex throughout the scope. More...
#include <vsn_mutex.h>
Public Member Functions | |
MutexLocker (Mutex *pMutex=nullptr) | |
Default constructor that blocks mutex. | |
~MutexLocker () | |
Destructor. | |
void | Unlock () |
Unlocks mutex. | |
void | Relock () |
Blocks mutex. Performing stops if mutex is not available. | |
Mutex * | GetMutex () const |
Returns pointer to mutex. | |
MutexLocker & | operator= (MutexLocker &&other) |
NO TRANSLATION. | |
MutexLocker class is a mutex wrapper that provides convenient ownership mechanism of mutex throughout the scope.
When MutexLocker is created, it takes mutex responsibility. When control leaves area, in which MutexLocker was created, MutexLocker destroys and mutex is released.