strict lock providing a const pointer access to the synchronized value type. More...
#include <synchronized_value.hpp>
Public Types | |
typedef T | value_type |
typedef Lockable | mutex_type |
Public Member Functions | |
const_strict_lock_ptr (T const &val, Lockable &mtx) | |
const_strict_lock_ptr (T const &val, Lockable &mtx, adopt_lock_t tag) BOOST_NOEXCEPT | |
const_strict_lock_ptr (BOOST_THREAD_RV_REF(const_strict_lock_ptr) other) BOOST_NOEXCEPT | |
Move constructor. More... | |
~const_strict_lock_ptr () | |
const T * | operator-> () const |
const T & | operator* () const |
Protected Attributes | |
boost::unique_lock< mutex_type > | lk_ |
T const & | value_ |
strict lock providing a const pointer access to the synchronized value type.
T | the value type. |
Lockable | the mutex type protecting the value type. |
typedef Lockable boost::const_strict_lock_ptr< T, Lockable >::mutex_type |
typedef T boost::const_strict_lock_ptr< T, Lockable >::value_type |
|
inline |
value | constant reference of the value to protect. |
mtx | reference to the mutex used to protect the value. locks the mutex mtx , stores a reference to it and to the value type value . |
|
inline |
|
inline |
Move constructor.
takes ownership of the mutex owned by other
, stores a reference to the mutex and the value type of other
.
|
inline |
|
inline |
References boost::const_strict_lock_ptr< T, Lockable >::value_.
|
inline |
References boost::const_strict_lock_ptr< T, Lockable >::value_.
|
protected |
|
protected |