![]() |
XII Release 0.1.0
|
Provides access to an object while managing a lock (e.g. a mutex) that ensures that during its lifetime the access to the object happens under the lock. More...
#include <LockedObject.h>
Public Member Functions | |
XII_ALWAYS_INLINE | xiiLockedObject (T &ref_lock, O *pObject) |
XII_ALWAYS_INLINE | xiiLockedObject (xiiLockedObject< T, O > &&rhs) |
xiiLockedObject (const xiiLockedObject< T, O > &rhs)=delete | |
void | operator= (const xiiLockedObject< T, O > &&rhs) |
void | operator= (const xiiLockedObject< T, O > &rhs)=delete |
XII_ALWAYS_INLINE bool | isValid () const |
Whether the encapsulated object exists at all or is nullptr. | |
O * | Borrow () |
const O * | Borrow () const |
O * | operator-> () |
const O * | operator-> () const |
O & | operator* () |
const O & | operator* () const |
bool | operator== (const O *rhs) const |
bool | operator! () const |
operator bool () const | |
Provides access to an object while managing a lock (e.g. a mutex) that ensures that during its lifetime the access to the object happens under the lock.