00001 /*========================================================================= 00002 00003 Program: Visualization Toolkit 00004 Module: $RCSfile: vtkXMLDataSetWriter.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 =========================================================================*/ 00031 #ifndef __vtkXMLDataSetWriter_h 00032 #define __vtkXMLDataSetWriter_h 00033 00034 #include "vtkXMLWriter.h" 00035 00036 class vtkCallbackCommand; 00037 00038 class VTK_IO_EXPORT vtkXMLDataSetWriter : public vtkXMLWriter 00039 { 00040 public: 00041 vtkTypeRevisionMacro(vtkXMLDataSetWriter,vtkXMLWriter); 00042 void PrintSelf(ostream& os, vtkIndent indent); 00043 static vtkXMLDataSetWriter* New(); 00044 00045 //BTX 00047 00048 vtkDataSet* GetInput(); 00049 //ETX 00051 00052 protected: 00053 vtkXMLDataSetWriter(); 00054 ~vtkXMLDataSetWriter(); 00055 00056 // see algorithm for more info 00057 virtual int FillInputPortInformation(int port, vtkInformation* info); 00058 00059 // Override writing method from superclass. 00060 virtual int WriteInternal(); 00061 00062 // Dummies to satisfy pure virtuals from superclass. 00063 const char* GetDataSetName(); 00064 const char* GetDefaultFileExtension(); 00065 00066 // Callback registered with the ProgressObserver. 00067 static void ProgressCallbackFunction(vtkObject*, unsigned long, void*, 00068 void*); 00069 // Progress callback from internal writer. 00070 virtual void ProgressCallback(vtkAlgorithm* w); 00071 00072 // The observer to report progress from the internal writer. 00073 vtkCallbackCommand* ProgressObserver; 00074 00075 private: 00076 vtkXMLDataSetWriter(const vtkXMLDataSetWriter&); // Not implemented. 00077 void operator=(const vtkXMLDataSetWriter&); // Not implemented. 00078 }; 00079 00080 #endif