VTK  9.0.2
vtkXMLHierarchicalBoxDataFileConverter.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkXMLHierarchicalBoxDataFileConverter.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 =========================================================================*/
25 #ifndef vtkXMLHierarchicalBoxDataFileConverter_h
26 #define vtkXMLHierarchicalBoxDataFileConverter_h
27 
28 #include "vtkIOXMLModule.h" // needed for export macro.
29 #include "vtkObject.h"
30 
31 class vtkXMLDataElement;
32 
33 class VTKIOXML_EXPORT vtkXMLHierarchicalBoxDataFileConverter : public vtkObject
34 {
35 public:
38  void PrintSelf(ostream& os, vtkIndent indent) override;
39 
41 
44  vtkSetStringMacro(InputFileName);
45  vtkGetStringMacro(InputFileName);
47 
49 
52  vtkSetStringMacro(OutputFileName);
53  vtkGetStringMacro(OutputFileName);
55 
59  bool Convert();
60 
61 protected:
64 
65  vtkXMLDataElement* ParseXML(const char* filename);
66 
67  // Returns GridDescription. VTK_UNCHANGED for invalid/failure.
68  int GetOriginAndSpacing(vtkXMLDataElement* ePrimary, double origin[3], double*& spacing);
69 
72  char* FilePath;
73  vtkSetStringMacro(FilePath);
74 
75 private:
77  void operator=(const vtkXMLHierarchicalBoxDataFileConverter&) = delete;
78 };
79 
80 #endif
a simple class to control print indentation
Definition: vtkIndent.h:34
abstract base class for most VTK objects
Definition: vtkObject.h:63
Represents an XML element and those nested inside.
converts older *.vth, *.vthb files to newer format.
bool Convert()
Converts the input file to new format and writes out the output file.
int GetOriginAndSpacing(vtkXMLDataElement *ePrimary, double origin[3], double *&spacing)
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
static vtkXMLHierarchicalBoxDataFileConverter * New()
vtkXMLDataElement * ParseXML(const char *filename)
@ spacing
Definition: vtkX3D.h:487