|
cgv
|
Classes | |
| struct | counter_type |
| struct to store the pointer with a count More... | |
Public Member Functions | |
| int | get_count () const |
| return current count | |
Protected Member Functions | |
| void | release () |
| decrement the count, delete if it is 0 | |
| T * | ref () const |
| return the pointer itself | |
| ref_ptr_impl (T *p=0) | |
| construct reference counted pointer | |
| ref_ptr_impl (const ref_ptr_impl< T, false > &r) | |
| copy construct from same pointer type and increment count | |
| template<typename S > | |
| ref_ptr_impl (const ref_ptr_impl< S, false > &s) | |
| copy construct from pointer of derived type with virtual destructor | |
Protected Attributes | |
| counter_type * | counter |
| store pointer to counter struct | |
Friends | |
| class | ref_ptr_impl< const T, is_ref_counted > |
|
inlineexplicitprotected |
construct reference counted pointer
Definition at line 73 of file ref_ptr.h.
References cgv::data::ref_ptr_impl< T, is_ref_counted >::counter.
|
inlineprotected |
copy construct from same pointer type and increment count
Definition at line 78 of file ref_ptr.h.
References cgv::data::ref_ptr_impl< T, is_ref_counted >::counter.
|
inlineprotected |
copy construct from pointer of derived type with virtual destructor
Definition at line 85 of file ref_ptr.h.
References cgv::data::ref_ptr_impl< T, is_ref_counted >::counter.
|
inline |
return current count
Definition at line 99 of file ref_ptr.h.
References cgv::data::ref_ptr_impl< T, is_ref_counted >::counter.
Referenced by cgv::data::ref_ptr< T, is_ref_counted >::empty(), and cgv::data::ref_ptr< T, is_ref_counted >::unique().
|
inlineprotected |
return the pointer itself
Definition at line 71 of file ref_ptr.h.
References cgv::data::ref_ptr_impl< T, is_ref_counted >::counter.
Referenced by cgv::data::ref_ptr< T, is_ref_counted >::operator!=(), cgv::data::ref_ptr< T, is_ref_counted >::operator*(), cgv::data::ref_ptr< T, is_ref_counted >::operator->(), cgv::data::ref_ptr< T, is_ref_counted >::operator<(), and cgv::data::ref_ptr< T, is_ref_counted >::operator==().
|
inlineprotected |
decrement the count, delete if it is 0
Definition at line 59 of file ref_ptr.h.
References cgv::data::ref_ptr_impl< T, is_ref_counted >::counter.
Referenced by cgv::data::ref_ptr< T, is_ref_counted >::clear(), cgv::data::ref_ptr< T, is_ref_counted >::operator=(), and cgv::data::ref_ptr< T, is_ref_counted >::~ref_ptr().
|
friend |
|
mutableprotected |
store pointer to counter struct
Definition at line 57 of file ref_ptr.h.
Referenced by cgv::data::ref_ptr_impl< T, is_ref_counted >::get_count(), cgv::data::ref_ptr_impl< T, is_ref_counted >::ref(), cgv::data::ref_ptr_impl< T, is_ref_counted >::ref_ptr_impl(), cgv::data::ref_ptr_impl< T, is_ref_counted >::ref_ptr_impl(), cgv::data::ref_ptr_impl< T, is_ref_counted >::ref_ptr_impl(), and cgv::data::ref_ptr_impl< T, is_ref_counted >::release().