Implements transparent reference counting in situations where forward references / cyclic include dependencies are a problem. More...
#include <itkSmartPointerForwardReference.h>
Public Member Functions | |
T * | GetPointer () const |
operator T * () const | |
T * | operator-> () const |
bool | operator< (const SmartPointerForwardReference &r) |
bool | operator<= (const SmartPointerForwardReference &r) |
SmartPointerForwardReference & | operator= (T *r) |
SmartPointerForwardReference & | operator= (const SmartPointerForwardReference &r) |
SmartPointerForwardReference & | operator= (const WeakPointer< T > &r) |
bool | operator> (const SmartPointerForwardReference &r) |
bool | operator>= (const SmartPointerForwardReference &r) |
T * | Print (std::ostream &os) const |
SmartPointerForwardReference () | |
SmartPointerForwardReference (const SmartPointerForwardReference< T > &p) | |
SmartPointerForwardReference (T *p) | |
SmartPointerForwardReference (const WeakPointer< T > &p) | |
~SmartPointerForwardReference () |
Implements transparent reference counting in situations where forward references / cyclic include dependencies are a problem.
SmartPointerForwardReference implements reference counting by overloading operator -> (and *) among others. This allows natural interface to the class referred to by the pointer without having to invoke special Register()/UnRegister() methods directly.
This class is nearly identical to itkSmartPointer except that is used in situations where forward references or cyclic include dependencies become a problem. This class requires that the .h file is included in the .h file of the class using it, and the .txx file is included in the .cxx/.txx file of the class using it. (Make sure that SmartPointerForwardReference.txx is included last in the .cxx/.txx list of includes.)
Definition at line 48 of file itkSmartPointerForwardReference.h.
itk::SmartPointerForwardReference< T >::SmartPointerForwardReference | ( | ) | [inline] |
Constructor
Definition at line 52 of file itkSmartPointerForwardReference.h.
itk::SmartPointerForwardReference< T >::SmartPointerForwardReference | ( | const SmartPointerForwardReference< T > & | p | ) |
Const constructor
itk::SmartPointerForwardReference< T >::SmartPointerForwardReference | ( | const WeakPointer< T > & | p | ) |
Construct from a WeakPointer
itk::SmartPointerForwardReference< T >::SmartPointerForwardReference | ( | T * | p | ) |
Constructor to pointer p
itk::SmartPointerForwardReference< T >::~SmartPointerForwardReference | ( | ) |
Destructor
T* itk::SmartPointerForwardReference< T >::GetPointer | ( | ) | const |
Access function to pointer.
itk::SmartPointerForwardReference< T >::operator T * | ( | ) | const |
Return pointer to object.
T* itk::SmartPointerForwardReference< T >::operator-> | ( | ) | const |
Overload operator ->
bool itk::SmartPointerForwardReference< T >::operator< | ( | const SmartPointerForwardReference< T > & | r | ) |
Comparison of pointers. Less than comparison.
bool itk::SmartPointerForwardReference< T >::operator<= | ( | const SmartPointerForwardReference< T > & | r | ) |
Comparison of pointers. Less than or equal to comparison.
SmartPointerForwardReference& itk::SmartPointerForwardReference< T >::operator= | ( | const WeakPointer< T > & | r | ) |
Overload operator assignment.
SmartPointerForwardReference& itk::SmartPointerForwardReference< T >::operator= | ( | const SmartPointerForwardReference< T > & | r | ) |
Overload operator assignment.
SmartPointerForwardReference& itk::SmartPointerForwardReference< T >::operator= | ( | T * | r | ) |
Overload operator assignment.
bool itk::SmartPointerForwardReference< T >::operator> | ( | const SmartPointerForwardReference< T > & | r | ) |
Comparison of pointers. Greater than comparison.
bool itk::SmartPointerForwardReference< T >::operator>= | ( | const SmartPointerForwardReference< T > & | r | ) |
Comparison of pointers. Greater than or equal to comparison.
T* itk::SmartPointerForwardReference< T >::Print | ( | std::ostream & | os | ) | const |
Function to print object pointed to