VTK
vtkXMLPStructuredDataWriter.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkXMLPStructuredDataWriter.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 =========================================================================*/
23 #ifndef vtkXMLPStructuredDataWriter_h
24 #define vtkXMLPStructuredDataWriter_h
25 
26 #include "vtkIOParallelXMLModule.h" // For export macro
27 #include "vtkXMLPDataWriter.h"
28 
29 #include <map> // for keeping track of extents
30 #include <vector> // for keeping track of extents
31 
33 
34 class VTKIOPARALLELXML_EXPORT vtkXMLPStructuredDataWriter : public vtkXMLPDataWriter
35 {
36 public:
38  void PrintSelf(ostream& os, vtkIndent indent) override;
39 
40 protected:
42  ~vtkXMLPStructuredDataWriter() override;
43 
44  virtual vtkXMLStructuredDataWriter* CreateStructuredPieceWriter()=0;
45  void WritePrimaryElementAttributes(ostream &os, vtkIndent indent) override;
46  void WritePPieceAttributes(int index) override;
47  vtkXMLWriter* CreatePieceWriter(int index) override;
48 
49  int WriteInternal() override;
50 
51  void PrepareSummaryFile() override;
52  int WritePiece(int index) override;
53 
54 private:
56  void operator=(const vtkXMLPStructuredDataWriter&) = delete;
57 
58  typedef std::map<int, std::vector<int> > ExtentsType;
59  ExtentsType Extents;
60 };
61 
62 #endif
int WriteInternal() override
Override writing method from superclass.
Superclass for VTK XML structured data writers.
Superclass for VTK&#39;s XML file writers.
Definition: vtkXMLWriter.h:62
a simple class to control print indentation
Definition: vtkIndent.h:39
Write data in a parallel XML format.
void WritePrimaryElementAttributes(ostream &os, vtkIndent indent) override
virtual vtkXMLWriter * CreatePieceWriter(int index)=0
Superclass for PVTK XML structured data writers.
virtual void WritePPieceAttributes(int index)
Write the attributes of the piece at the given index.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
virtual void PrepareSummaryFile()
Collect information between ranks before writing the summary file.
int WritePiece(int index) override
Write a piece of the dataset on disk.