|
MADNESS 0.10.1
|
Remote counter implementation object. More...
#include <worldref.h>


Public Member Functions | |
| RemoteCounterImpl (const std::shared_ptr< T > &p) | |
| virtual | ~RemoteCounterImpl () |
| const std::shared_ptr< T > & | get_shared () const |
| Shared pointer accessor. | |
| virtual void * | key () const |
| Counter key accessor. | |
Public Member Functions inherited from madness::detail::RemoteCounterBase | |
| RemoteCounterBase () | |
| virtual | ~RemoteCounterBase () |
| void | add_ref () |
| Increment the reference count. | |
| template<typename T > | |
| const std::shared_ptr< T > & | get_shared () const |
| Shared pointer accessor. | |
| bool | release () |
| Decrement the reference count. | |
| long | use_count () const |
| Remote and local counter accessor. | |
Private Attributes | |
| std::shared_ptr< T > | pointer_ |
| pointer that is remotely referenced | |
Remote counter implementation object.
This class stores a shared pointer in memory to ensure that the referenced object is valid as long as there are outstanding remote references.
| T | The type of the referenced shared_ptr object. |
|
inlineexplicit |
|
inlinevirtual |
|
inline |
Shared pointer accessor.
References madness::detail::RemoteCounterImpl< T >::pointer_.
|
inlinevirtual |
Counter key accessor.
The key is the pointer for which the remote counter is counting references.
Implements madness::detail::RemoteCounterBase.
References madness::detail::RemoteCounterImpl< T >::pointer_.
|
private |
pointer that is remotely referenced
Referenced by madness::detail::RemoteCounterImpl< T >::get_shared(), and madness::detail::RemoteCounterImpl< T >::key().