Wrapper around std::unique_lock style lock for MutexType.
Declared in <sync.h>
template<typename MutexType>
class [[scoped_lockable]] UniqueLock
: public MutexType::unique_lock
| Name | Description |
|---|---|
MutexType::unique_lock |
| Name | Description |
|---|---|
reverse_lock | An RAII-style reverse lock. Unlocks on construction and locks on destruction. |
| Name | Description |
|---|---|
UniqueLock [constructor] | Acquire a lock on the given mutex, registering it for lock-order checking. |
UniqueLock [constructor] | Acquire a lock on the given mutex pointer, doing nothing if it is null. |
~UniqueLock [destructor] | Release the lock if held and update lock-order bookkeeping. |
operator bool | Report whether this lock currently owns its mutex. |
| Name | Description |
|---|---|
UniqueLock [constructor] | Construct an empty lock that owns no mutex (needed for reverse_lock). |
| Name | Description |
|---|---|
UniqueLock::reverse_lock | An RAII-style reverse lock. Unlocks on construction and locks on destruction. |