00001 /*========================================================================= 00002 00003 Program: Visualization Toolkit 00004 Module: $RCSfile: vtkAppendFilter.h,v $ 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 =========================================================================*/ 00047 #ifndef __vtkAppendFilter_h 00048 #define __vtkAppendFilter_h 00049 00050 #include "vtkDataSetToUnstructuredGridFilter.h" 00051 00052 class vtkDataSetCollection; 00053 00054 class VTK_GRAPHICS_EXPORT vtkAppendFilter : public vtkDataSetToUnstructuredGridFilter 00055 { 00056 public: 00057 static vtkAppendFilter *New(); 00058 00059 vtkTypeRevisionMacro(vtkAppendFilter,vtkDataSetToUnstructuredGridFilter); 00060 void PrintSelf(ostream& os, vtkIndent indent); 00061 00063 void AddInput(vtkDataSet *in); 00064 00066 00067 vtkDataSet *GetInput(int idx); 00068 vtkDataSet *GetInput() 00069 {return this->GetInput( 0 );} 00071 00073 void RemoveInput(vtkDataSet *in); 00074 00077 vtkDataSetCollection *GetInputList(); 00078 00079 protected: 00080 vtkAppendFilter(); 00081 ~vtkAppendFilter(); 00082 00083 // Usual data generation method 00084 void Execute(); 00085 00086 // list of data sets to append together. 00087 // Here as a convenience. It is a copy of the input array. 00088 vtkDataSetCollection *InputList; 00089 00090 private: 00091 // hide the superclass' AddInput() from the user and the compiler 00092 void AddInput(vtkDataObject *) 00093 { vtkErrorMacro( << "AddInput() must be called with a vtkDataSet not a vtkDataObject."); }; 00094 void RemoveInput(vtkDataObject *input) 00095 { this->vtkProcessObject::RemoveInput(input); }; 00096 private: 00097 vtkAppendFilter(const vtkAppendFilter&); // Not implemented. 00098 void operator=(const vtkAppendFilter&); // Not implemented. 00099 }; 00100 00101 00102 #endif 00103 00104