00001 /*========================================================================= 00002 00003 Program: Visualization Toolkit 00004 Module: vtkCompositeDataSet.h 00005 00006 Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen 00007 All rights reserved. 00008 See Copyright.txt or http://www.kitware.com/Copyright.htm for details. 00009 00010 This software is distributed WITHOUT ANY WARRANTY; without even 00011 the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR 00012 PURPOSE. See the above copyright notice for more information. 00013 00014 =========================================================================*/ 00032 #ifndef __vtkCompositeDataSet_h 00033 #define __vtkCompositeDataSet_h 00034 00035 #include "vtkDataObject.h" 00036 00037 class vtkCompositeDataIterator; 00038 class vtkCompositeDataSetInternals; 00039 class vtkInformation; 00040 class vtkInformationStringKey; 00041 00042 class VTK_FILTERING_EXPORT vtkCompositeDataSet : public vtkDataObject 00043 { 00044 public: 00045 vtkTypeMacro(vtkCompositeDataSet, vtkDataObject); 00046 void PrintSelf(ostream& os, vtkIndent indent); 00047 00049 virtual vtkCompositeDataIterator* NewIterator(); 00050 00052 virtual int GetDataObjectType() {return VTK_COMPOSITE_DATA_SET;} 00053 00055 virtual vtkAlgorithmOutput* GetProducerPort(); 00056 00060 virtual void CopyStructure(vtkCompositeDataSet* input); 00061 00066 virtual void SetDataSet(vtkCompositeDataIterator* iter, vtkDataObject* dataObj); 00067 00072 virtual vtkDataObject* GetDataSet(vtkCompositeDataIterator* iter); 00073 00080 virtual vtkInformation* GetMetaData(vtkCompositeDataIterator* iter); 00081 00086 virtual int HasMetaData(vtkCompositeDataIterator* iter); 00087 00090 virtual unsigned long GetActualMemorySize(); 00091 00092 //BTX 00094 00095 static vtkCompositeDataSet* GetData(vtkInformation* info); 00096 static vtkCompositeDataSet* GetData(vtkInformationVector* v, int i=0); 00097 //ETX 00099 00101 virtual void Initialize(); 00102 00104 00105 virtual void ShallowCopy(vtkDataObject *src); 00106 virtual void DeepCopy(vtkDataObject *src); 00108 00112 virtual vtkIdType GetNumberOfPoints(); 00113 00115 static vtkInformationStringKey* NAME(); 00116 00117 //BTX 00118 protected: 00119 vtkCompositeDataSet(); 00120 ~vtkCompositeDataSet(); 00121 00123 void SetNumberOfChildren(unsigned int num); 00124 00126 unsigned int GetNumberOfChildren(); 00127 00130 void SetChild(unsigned int index, vtkDataObject*); 00131 00133 void RemoveChild(unsigned int index); 00134 00136 vtkDataObject* GetChild(unsigned int num); 00137 00141 vtkInformation* GetChildMetaData(unsigned int index); 00142 00144 void SetChildMetaData(unsigned int index, vtkInformation* info); 00145 00148 int HasChildMetaData(unsigned int index); 00149 00150 // The internal datastructure. Subclasses need not access this directly. 00151 vtkCompositeDataSetInternals* Internals; 00152 00153 friend class vtkCompositeDataIterator; 00154 private: 00155 vtkCompositeDataSet(const vtkCompositeDataSet&); // Not implemented. 00156 void operator=(const vtkCompositeDataSet&); // Not implemented. 00157 //ETX 00158 }; 00159 00160 #endif 00161 00162