Go to the documentation of this file.
29 #ifndef vtkInformationKey_h
30 #define vtkInformationKey_h
32 #include "vtkCommonCoreModule.h"
58 const char* GetName();
64 const char* GetLocation();
92 { this->ShallowCopy(from, to); }
163 #define vtkInformationKeySetStringMacro(name) \
164 virtual void Set##name (const char* _arg) \
166 if ( this->name == nullptr && _arg == nullptr) { return;} \
167 if ( this->name && _arg && (!strcmp(this->name,_arg))) { return;} \
168 delete [] this->name; \
171 size_t n = strlen(_arg) + 1; \
172 char *cp1 = new char[n]; \
173 const char *cp2 = (_arg); \
175 do { *cp1++ = *cp2++; } while ( --n ); \
179 this->name = nullptr; \
198 void ConstructClass(
const char*);
208 #define vtkInformationKeyMacro(CLASS, NAME, type) \
209 static vtkInformation##type##Key* CLASS##_##NAME = \
210 new vtkInformation##type##Key(#NAME, #CLASS); \
211 vtkInformation##type##Key* CLASS::NAME() \
213 return CLASS##_##NAME; \
215 #define vtkInformationKeySubclassMacro(CLASS, NAME, type, super) \
216 static vtkInformation##type##Key* CLASS##_##NAME = \
217 new vtkInformation##type##Key(#NAME, #CLASS); \
218 vtkInformation##super##Key* CLASS::NAME() \
220 return CLASS##_##NAME; \
222 #define vtkInformationKeyRestrictedMacro(CLASS, NAME, type, required) \
223 static vtkInformation##type##Key* CLASS##_##NAME = \
224 new vtkInformation##type##Key(#NAME, #CLASS, required); \
225 vtkInformation##type##Key* CLASS::NAME() \
227 return CLASS##_##NAME; \
void operator=(const vtkObjectBase &)
void Print(ostream &os)
Print an object to an ostream.
virtual void Register(vtkObjectBase *o)
Increase the reference count (mark as used by another object).
abstract base class for most VTK objects
a simple class to control print indentation
Detect and break reference loops.
virtual void PrintSelf(ostream &os, vtkIndent indent)
Methods invoked by print to print information about the object including superclasses.
virtual void UnRegister(vtkObjectBase *o)
Decrease the reference count (release by another object).