|
CeresEngine 0.2.0
A game development framework
|
The class SharedLock is a general-purpose shared mutex ownership wrapper allowing deferred locking, timed locking and transfer of lock ownership.
More...
#include <CeresEngine/Foundation/Threading/Threading.hpp>
Private Types | |
| using | super = std::shared_lock< Mutex > |
The class SharedLock is a general-purpose shared mutex ownership wrapper allowing deferred locking, timed locking and transfer of lock ownership.
Locking a SharedLock locks the associated shared mutex in shared mode (to lock it in exclusive mode, UniqueLock can be used).
The SharedLock class is movable, but not copyable – it meets the requirements of MoveConstructible and MoveAssignable but not of CopyConstructible or CopyAssignable.
In order to wait in a shared mutex in shared ownership mode, ConditionVariable can be used.
| Mutex | the type of the shared mutex to lock. The type must meet the SharedMutex requirements |
|
private |