Wrapper around a class managing its own reference counter. More...
#include <arccore/base/Ref.h>
Public Member Functions | |
| ReferenceCounterWrapper (InstanceType *ptr, const RefBase::BasicDeleterBase &) | |
| Constructor with an empty deleter. In this case, it does not need to be kept. | |
| template<typename U> | |
| ReferenceCounterWrapper (InstanceType *ptr, const U &deleter_base) | |
| ReferenceCounterWrapper (InstanceType *ptr) | |
| template<typename T, typename X = typename std::is_convertible<T*, InstanceType*>::type> | |
| ReferenceCounterWrapper (const ReferenceCounterWrapper< T > &r) | |
| Allows conversion if 'T*' and 'InstanceType*' are convertible. | |
| InstanceType * | get () const |
| Returns the instance. | |
| void | reset () |
| Resets the currently associated reference. | |
| RefBase::DeleterBase * | getDeleter () |
Wrapper around a class managing its own reference counter.
The class InstanceType must manage its own reference counter and its own destruction.
Definition at line 33 of file arccore/src/base/arccore/base/Ref.h.
|
inline |
Constructor with an empty deleter. In this case, it does not need to be kept.
Definition at line 45 of file arccore/src/base/arccore/base/Ref.h.
Referenced by ReferenceCounterWrapper().
|
inline |
Definition at line 51 of file arccore/src/base/arccore/base/Ref.h.
|
inlineexplicit |
Definition at line 59 of file arccore/src/base/arccore/base/Ref.h.
|
inlineexplicit |
Allows conversion if 'T*' and 'InstanceType*' are convertible.
Definition at line 67 of file arccore/src/base/arccore/base/Ref.h.
References get(), and ReferenceCounterWrapper().
|
inline |
Returns the instance.
Definition at line 77 of file arccore/src/base/arccore/base/Ref.h.
Referenced by ReferenceCounterWrapper().
|
inline |
Definition at line 82 of file arccore/src/base/arccore/base/Ref.h.
|
inline |
Resets the currently associated reference.
Definition at line 80 of file arccore/src/base/arccore/base/Ref.h.