 |
VTK
9.0.1
|
Go to the documentation of this file.
26 #ifndef vtkSmartPointerBase_h
27 #define vtkSmartPointerBase_h
29 #include "vtkCommonCoreModule.h"
104 #define VTK_SMART_POINTER_BASE_DEFINE_OPERATOR(op) \
105 inline bool operator op(const vtkSmartPointerBase& l, const vtkSmartPointerBase& r) \
107 return (static_cast<void*>(l.GetPointer()) op static_cast<void*>(r.GetPointer())); \
109 inline bool operator op(vtkObjectBase* l, const vtkSmartPointerBase& r) \
111 return (static_cast<void*>(l) op static_cast<void*>(r.GetPointer())); \
113 inline bool operator op(const vtkSmartPointerBase& l, vtkObjectBase* r) \
115 return (static_cast<void*>(l.GetPointer()) op static_cast<void*>(r)); \
127 #undef VTK_SMART_POINTER_BASE_DEFINE_OPERATOR
vtkSmartPointerBase & operator=(vtkObjectBase *r)
Assign object to reference.
Non-templated superclass for vtkSmartPointer.
vtkSmartPointerBase() noexcept
Initialize smart pointer to nullptr.
vtkObjectBase * GetPointer() const noexcept
Get the contained pointer.
void Report(vtkGarbageCollector *collector, const char *desc)
Report the reference held by the smart pointer to a collector.
abstract base class for most VTK objects
Detect and break reference loops.
VTKCOMMONCORE_EXPORT ostream & operator<<(ostream &os, const vtkSmartPointerBase &p)
Compare smart pointer values.
vtkSmartPointerBase & operator=(const vtkSmartPointerBase &r)
~vtkSmartPointerBase()
Destroy smart pointer and remove the reference to its object.
vtkSmartPointerBase(vtkObjectBase *r, const NoReference &)
#define VTK_SMART_POINTER_BASE_DEFINE_OPERATOR(op)