VTK
vtkXMLDataObjectWriter.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkXMLDataObjectWriter.h
5 
6  Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
7  All rights reserved.
8  See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
9 
10  This software is distributed WITHOUT ANY WARRANTY; without even
11  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
12  PURPOSE. See the above copyright notice for more information.
13 
14 =========================================================================*/
32 #ifndef vtkXMLDataObjectWriter_h
33 #define vtkXMLDataObjectWriter_h
34 
35 #include "vtkIOXMLModule.h" // For export macro
36 #include "vtkXMLWriter.h"
37 
38 class vtkCallbackCommand;
39 
40 class VTKIOXML_EXPORT vtkXMLDataObjectWriter : public vtkXMLWriter
41 {
42 public:
44  void PrintSelf(ostream& os, vtkIndent indent) override;
45  static vtkXMLDataObjectWriter* New();
46 
51 
58  static vtkXMLWriter* NewWriter(int dataset_type);
59 
60 protected:
62  ~vtkXMLDataObjectWriter() override;
63 
64  // see algorithm for more info
66 
67  // Override writing method from superclass.
68  int WriteInternal() override;
69 
70  // Dummies to satisfy pure virtuals from superclass.
71  const char* GetDataSetName() override;
72  const char* GetDefaultFileExtension() override;
73 
74  // Callback registered with the InternalProgressObserver.
75  static void ProgressCallbackFunction(vtkObject*, unsigned long, void*,
76  void*);
77  // Progress callback from internal writer.
78  virtual void ProgressCallback(vtkAlgorithm* w);
79 
80  // The observer to report progress from the internal writer.
82 
83 private:
85  void operator=(const vtkXMLDataObjectWriter&) = delete;
86 };
87 
88 #endif
virtual const char * GetDataSetName()=0
abstract base class for most VTK objects
Definition: vtkObject.h:59
vtkDataObject * GetInput()
Assign a data object as input.
Definition: vtkXMLWriter.h:235
Store vtkAlgorithm input/output information.
abstract class to specify dataset behavior
Definition: vtkDataSet.h:62
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
supports function callbacks
Superclass for all sources, filters, and sinks in VTK.
Definition: vtkAlgorithm.h:59
Superclass for VTK's XML file writers.
Definition: vtkXMLWriter.h:62
vtkCallbackCommand * InternalProgressObserver
a simple class to control print indentation
Definition: vtkIndent.h:39
virtual int WriteInternal()
virtual const char * GetDefaultFileExtension()=0
Get the default file extension for files written by this writer.
virtual int FillInputPortInformation(int port, vtkInformation *info)
Fill the input port information objects for this algorithm.
static vtkAlgorithm * New()
Write any type of VTK XML file.