Table of Contents
NAME
vtkObject - abstract base class for most of the vtk objects
SYNOPSIS
#include "/opt/vtk-c++/common/vtkObject.h"
class VTK_EXPORT vtkObject
- vtkObject(); create a vtk object
- virtual void Delete();
- delete a vtk object.
- virtual ~vtkObject(); use Delete() whenever possible
static vtkObject *New() {return new vtkObject;};
virtual const char *GetClassName() {return "vtkObject";};
#ifdef _WIN32
void* operator new( size_t tSize, const char *, int);
void* operator new( size_t tSize );
void operator delete( void* p );
#endif
virtual void DebugOn();
virtual void DebugOff();
unsigned char GetDebug();
void SetDebug(unsigned char debugFlag);
virtual unsigned long GetMTime();
virtual void Modified();
virtual void PrintSelf(ostream& os, vtkIndent indent);
void Print(ostream& os);
virtual void PrintHeader(ostream& os, vtkIndent indent);
virtual void PrintTrailer(ostream& os, vtkIndent indent);
static void BreakOnError();
static void SetGlobalWarningDisplay(int val);
static void GlobalWarningDisplayOn() {vtkObject::SetGlobalWarningDisplay(1);};
static void GlobalWarningDisplayOff() {vtkObject::SetGlobalWarningDisplay(0);};
static int GetGlobalWarningDisplay();
DESCRIPTION
vtkObject is the base class for many objects in the visualization toolkit. vtkObject provides methods for tracking
modification times, debugging, and printing. Most objects created within the vtk framework should be a subclass of vtkObject or one of its children. The few exceptions tend to be very small helper classes that usually never get instantiated or situations where multiple inheritance gets in the way.
SUMMARY
void Modified()
This is a global flag that controls whether any debug, warning or error messages are displayed. unsigned char
- Debug;
- Enable debug messages vtkTimeStamp MTime; Keep track of modification time BTX ETX Update the modification time for this object. Many filters rely on the modification time to determine if they need to recompute their data.
ostream& operator<<(ostream& os, vtkObject& o)
This operator allows all subclasses of vtkObject to be printed via <<. It in turn invokes the Print method, which in turn will invoke the PrintSelf method that all objects should define, if they have anything interesting to print out.
vtkObject()
Create an object with Debug turned off and modified time initialized to zero.
void Delete()
Delete a vtk object. This method should always be used to delete an object when the new operator was used to create it. Using the C++ delete method will not work with reference counting.
unsigned long int GetMTime()
Return the modification for this object.
void PrintSelf(ostream& os, vtkIndent indent)
Chaining method to print an object's instance variables, as well as its superclasses.
void DebugOn()
Turn debugging output on.
void DebugOff()
Turn debugging output off.
unsigned char GetDebug()
Get the value of the debug flag.
void SetDebug(unsigned char debugFlag)
Set the value of the debug flag. A non-zero value turns debugging on.
void BreakOnError()
This method is called when vtkErrorMacro executes. It allows the debugger to break on error.
Table of Contents