25 #ifndef vtkWeakPointerBase_h
26 #define vtkWeakPointerBase_h
28 #include "vtkCommonCoreModule.h"
31 class vtkObjectBaseToWeakPointerBaseFriendship;
85 friend class vtkObjectBaseToWeakPointerBaseFriendship;
99 #define VTK_WEAK_POINTER_BASE_DEFINE_OPERATOR(op) \
100 inline bool operator op(const vtkWeakPointerBase& l, const vtkWeakPointerBase& r) \
102 return (static_cast<void*>(l.GetPointer()) op static_cast<void*>(r.GetPointer())); \
104 inline bool operator op(vtkObjectBase* l, const vtkWeakPointerBase& r) \
106 return (static_cast<void*>(l) op static_cast<void*>(r.GetPointer())); \
108 inline bool operator op(const vtkWeakPointerBase& l, vtkObjectBase* r) \
110 return (static_cast<void*>(l.GetPointer()) op static_cast<void*>(r)); \
122 #undef VTK_WEAK_POINTER_BASE_DEFINE_OPERATOR
vtkWeakPointerBase() noexcept
Initialize smart pointer to nullptr.
#define VTK_WEAK_POINTER_BASE_DEFINE_OPERATOR(op)
VTKCOMMONCORE_EXPORT ostream & operator<<(ostream &os, const vtkWeakPointerBase &p)
Compare smart pointer values.
Non-templated superclass for vtkWeakPointer.
abstract base class for most VTK objects