A reference counter base class. More...
#include <intrusive_ref_counter.hpp>
Public Member Functions | |
intrusive_ref_counter () BOOST_NOEXCEPT | |
Default constructor. More... | |
intrusive_ref_counter (intrusive_ref_counter const &) BOOST_NOEXCEPT | |
Copy constructor. More... | |
intrusive_ref_counter & | operator= (intrusive_ref_counter const &) BOOST_NOEXCEPT |
Assignment. More... | |
unsigned int | use_count () const BOOST_NOEXCEPT |
Friends | |
void | intrusive_ptr_add_ref (const intrusive_ref_counter< DerivedT, CounterPolicyT > *p) BOOST_NOEXCEPT |
Destructor. More... | |
void | intrusive_ptr_release (const intrusive_ref_counter< DerivedT, CounterPolicyT > *p) BOOST_NOEXCEPT |
A reference counter base class.
This base class can be used with user-defined classes to add support for intrusive_ptr
. The class contains a reference counter defined by the CounterPolicyT
. Upon releasing the last intrusive_ptr
referencing the object derived from the intrusive_ref_counter
class, operator delete
is automatically called on the pointer to the object.
The other template parameter, DerivedT
, is the user's class that derives from intrusive_ref_counter
.
|
inline |
Default constructor.
use_count() == 0
|
inline |
Copy constructor.
use_count() == 0
|
inline |
Assignment.
|
inline |
References boost::serialization::load().
|
friend |
Destructor.
|
friend |