vtk-dicom
0.8.17
|
abstract base class for most VTK objects More...
#include <vtkObjectBase.h>
Public Member Functions | |
const char * | GetClassName () const |
virtual vtkTypeBool | IsA (const char *name) |
virtual void | Delete () |
virtual void | FastDelete () |
void | InitializeObjectBase () |
void | Print (ostream &os) |
virtual void | PrintSelf (ostream &os, vtkIndent indent) |
virtual void | PrintHeader (ostream &os, vtkIndent indent) |
virtual void | PrintTrailer (ostream &os, vtkIndent indent) |
virtual void | Register (vtkObjectBase *o) |
virtual void | UnRegister (vtkObjectBase *o) |
int | GetReferenceCount () |
void | SetReferenceCount (int) |
void | PrintRevisions (ostream &) |
Static Public Member Functions | |
static vtkTypeBool | IsTypeOf (const char *name) |
static vtkObjectBase * | New () |
Protected Member Functions | |
virtual void | CollectRevisions (ostream &) |
virtual void | RegisterInternal (vtkObjectBase *, vtkTypeBool check) |
virtual void | UnRegisterInternal (vtkObjectBase *, vtkTypeBool check) |
virtual void | ReportReferences (vtkGarbageCollector *) |
vtkObjectBase (const vtkObjectBase &) | |
void | operator= (const vtkObjectBase &) |
Protected Attributes | |
vtkAtomicInt32 | ReferenceCount |
vtkWeakPointerBase ** | WeakPointers |
Friends | |
class | vtkGarbageCollectorToObjectBaseFriendship |
class | vtkWeakPointerBaseToObjectBaseFriendship |
VTKCOMMONCORE_EXPORT ostream & | operator<< (ostream &os, vtkObjectBase &o) |
abstract base class for most VTK objects
vtkObjectBase is the base class for all reference counted classes in the VTK. These classes include vtkCommand classes, vtkInformationKey classes, and vtkObject classes.
vtkObjectBase performs reference counting: objects that are reference counted exist as long as another object uses them. Once the last reference to a reference counted object is removed, the object will spontaneously destruct.
Constructor and destructor of the subclasses of vtkObjectBase should be protected, so that only New() and UnRegister() actually call them. Debug leaks can be used to see if there are any objects left with nonzero reference count.
|
virtual |
Delete a VTK object. This method should always be used to delete an object when the New() method was used to create it. Using the C++ delete method will not work with reference counting.
|
virtual |
Delete a reference to this object. This version will not invoke garbage collection and can potentially leak the object if it is part of a reference loop. Use this method only when it is known that the object has another reference and would not be collected if a full garbage collection check were done.
const char* vtkObjectBase::GetClassName | ( | ) | const |
Return the class name as a string.
|
inline |
Return the current reference count of this object.
|
virtual |
Return 1 if this class is the same type of (or a subclass of) the named class. Returns 0 otherwise. This method works in combination with vtkTypeMacro found in vtkSetGet.h.
Reimplemented in vtkThreadedImageAlgorithm, vtkScancoCTReader, vtkNIFTIWriter, vtkNIFTIReader, vtkNIFTIHeader, vtkImageWriter, vtkImageReader2, vtkImageReader, vtkImageAlgorithm, vtkDICOMWriter, vtkDICOMUtilities, vtkDICOMUIDGenerator, vtkDICOMToRAS, vtkDICOMSorter, vtkDICOMSliceSorter, vtkDICOMSCGenerator, vtkDICOMReader, vtkDICOMParser, vtkDICOMMRGenerator, vtkDICOMGenerator, vtkDICOMFileSorter, vtkDICOMDirectory, vtkDICOMCTRectifier, vtkDICOMCTGenerator, vtkDICOMCompiler, vtkDICOMApplyRescale, vtkDICOMApplyPalette, vtkDICOMAlgorithm, and vtkAlgorithm.
|
static |
Return 1 if this class type is the same type of (or a subclass of) the named class. Returns 0 otherwise. This method works in combination with vtkTypeMacro found in vtkSetGet.h.
|
inlinestatic |
Create an object with Debug turned off, modified time initialized to zero, and reference counting on.
void vtkObjectBase::Print | ( | ostream & | os | ) |
Print an object to an ostream. This is the method to call when you wish to see print the internal state of an object.
|
inline |
Legacy. Do not call.
|
virtual |
Methods invoked by print to print information about the object including superclasses. Typically not called by the user (use Print() instead) but used in the hierarchical print process to combine the output of several classes.
Reimplemented in vtkThreadedImageAlgorithm, vtkObject, vtkImageAlgorithm, vtkAlgorithm, vtkScancoCTReader, vtkNIFTIWriter, vtkNIFTIReader, vtkNIFTIHeader, vtkDICOMWriter, vtkDICOMUtilities, vtkDICOMUIDGenerator, vtkDICOMToRAS, vtkDICOMSorter, vtkDICOMSliceSorter, vtkDICOMSCGenerator, vtkDICOMReader, vtkDICOMParser, vtkDICOMMRGenerator, vtkDICOMGenerator, vtkDICOMFileSorter, vtkDICOMDirectory, vtkDICOMCTRectifier, vtkDICOMCTGenerator, vtkDICOMCompiler, vtkDICOMApplyRescale, vtkDICOMApplyPalette, vtkDICOMAlgorithm, vtkImageWriter, vtkImageReader2, and vtkImageReader.
|
virtual |
Increase the reference count (mark as used by another object).
Reimplemented in vtkAlgorithm.
void vtkObjectBase::SetReferenceCount | ( | int | ) |
Sets the reference count. (This is very dangerous, use with care.)
|
virtual |
Decrease the reference count (release by another object). This has the same effect as invoking Delete() (i.e., it reduces the reference count by 1).
Reimplemented in vtkAlgorithm.