#include <Ref.h>
Public Types | |
| typedef std::vector< Ref< T > > | vector |
| typedef std::list< Ref< T > > | list |
Public Methods | |
| Ref () | |
| Create a null reference. | |
| Ref (T *ptr) | |
| Create a new reference. | |
| Ref (LinkBase const &r) | |
| Light-weight copy with reference counting. | |
| template<typename Q> | Ref (Ref< Q > const &r) |
| Light-weight copy with reference counting. | |
| Ref (Ref const &r) | |
| Light-weight copy with reference counting. | |
| ~Ref () | |
| Decrement the reference count, and potentially destroy the referenced object. | |
| bool | unique () const |
| Returns true if this is the only reference. | |
| int | count () const |
| Get the number of outstanding references. | |
| template<class Q> Ref const & | operator= (Ref< Q > const &r) |
| Light-weight copy with reference counting. | |
| Ref const & | operator= (Ref const &r) |
| Light-weight copy with reference counting. | |
| LinkBase const & | operator= (LinkBase const &r) |
| Light-weight copy with reference counting. | |
| template<class Q> Q * | operator= (Q *ptr) |
| Raw pointer assignment. | |
| void * | operator= (void *ptr) |
| Raw pointer assignment for assigning NULL. | |
| T * | get () const |
| Dereference. | |
| T * | operator-> () const |
| Dereference. | |
| T & | operator * () const |
| Dereference. | |
| bool | operator! () const |
| Test for null pointer. | |
| bool | valid () const |
| Test for non-null pointer. | |
| template<class Q> bool | operator== (Ref< Q > const &p) const |
| Comparison with other simdata pointers. | |
| bool | operator== (Referenced const *p) const |
| Comparison with other simdata pointers. | |
| template<class Q> bool | operator!= (Ref< Q > const &p) const |
| Comparison with other simdata pointers. | |
| bool | operator!= (Referenced const *p) const |
| Comparison with other simdata pointers. | |
Protected Methods | |
| template<class Q> void | _rebind (Q *ptr) |
| Rebind to a new object. | |
Protected Attributes | |
| T * | _reference |
| The actual pointer. | |
Reference counting smart-pointer for use with simdata::Referenced objects.
Classes derived from Reference should be handled with Ref<T> smart pointers, or Link<T> dynamic references.
|
|||||
|
|
|
|||||
|
|
|
|||||||||
|
Create a null reference.
|
|
||||||||||
|
Create a new reference.
|
|
||||||||||
|
Light-weight copy with reference counting.
|
|
||||||||||||||
|
Light-weight copy with reference counting.
|
|
||||||||||
|
Light-weight copy with reference counting.
|
|
|||||||||
|
Decrement the reference count, and potentially destroy the referenced object.
|
|
||||||||||||||
|
Rebind to a new object.
|
|
|||||||||
|
Get the number of outstanding references.
|
|
|||||||||
|
Dereference.
|
|
|||||||||
|
Dereference.
|
|
|||||||||
|
Test for null pointer.
|
|
||||||||||
|
Comparison with other simdata pointers.
|
|
||||||||||||||
|
Comparison with other simdata pointers.
|
|
|||||||||
|
Dereference.
|
|
||||||||||
|
Raw pointer assignment for assigning NULL. Assigning any pointer other than '0' will assert. |
|
||||||||||||||
|
Raw pointer assignment.
|
|
||||||||||
|
Light-weight copy with reference counting.
|
|
||||||||||
|
Light-weight copy with reference counting.
|
|
||||||||||||||
|
Light-weight copy with reference counting.
|
|
||||||||||
|
Comparison with other simdata pointers.
|
|
||||||||||||||
|
Comparison with other simdata pointers.
|
|
|||||||||
|
Returns true if this is the only reference.
|
|
|||||||||
|
Test for non-null pointer.
|
|
|||||
|
The actual pointer.
|
|
SimData version pre-0.4.0. For more information on SimData, visit the SimData Homepage. Generated on Tue Oct 14 12:06:42 2003, using Doxygen 1.2.18. |