|
libmoost
|
Objects of this class represent an upgradable lock of the guarded_ptr's mutex. More...
#include <guarded_ptr.hpp>


Classes | |
| class | upgrade |
| Objects of this class represent an upgrade of an upgradable lock. More... | |
Public Member Functions | |
| upgradable_access (guarded_ptr &guard) | |
| ~upgradable_access () | |
| const_reference | operator* () const |
| const_pointer | operator-> () const |
Private Attributes | |
| guarded_ptr & | m_gptr |
| bool | m_upgraded |
Objects of this class represent an upgradable lock of the guarded_ptr's mutex.
upgradable_access objects can only be constructed from guarded_ptr objects. They yield const-pointers to the object referenced by the guarded_ptr. An upgrade object can be constructed from the upgradable_access object, which leads to upgrading the upgradable lock to an exclusive lock. The upgrade object can deliver a non-const pointer to the referenced object.
The upgradable_access object must never outlive the underlying guarded_ptr object.
Definition at line 219 of file guarded_ptr.hpp.
| moost::guarded_ptr< T >::upgradable_access::upgradable_access | ( | guarded_ptr & | guard | ) | [inline] |
Definition at line 222 of file guarded_ptr.hpp.
| moost::guarded_ptr< T >::upgradable_access::~upgradable_access | ( | ) | [inline] |
Definition at line 228 of file guarded_ptr.hpp.
| const_reference moost::guarded_ptr< T >::upgradable_access::operator* | ( | ) | const [inline] |
Definition at line 240 of file guarded_ptr.hpp.
| const_pointer moost::guarded_ptr< T >::upgradable_access::operator-> | ( | ) | const [inline] |
Definition at line 244 of file guarded_ptr.hpp.
guarded_ptr& moost::guarded_ptr< T >::upgradable_access::m_gptr [private] |
Definition at line 291 of file guarded_ptr.hpp.
bool moost::guarded_ptr< T >::upgradable_access::m_upgraded [private] |
Definition at line 292 of file guarded_ptr.hpp.