VTK  9.0.1
vtkXMLTableWriter.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkXMLTableWriter.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 vtkXMLTableWriter_h
24 #define vtkXMLTableWriter_h
25 
26 #include "vtkIOXMLModule.h" // For export macro
27 #include "vtkXMLWriter.h"
28 
29 class vtkTable;
30 
31 class VTKIOXML_EXPORT vtkXMLTableWriter : public vtkXMLWriter
32 {
33 public:
35  void PrintSelf(ostream& os, vtkIndent indent) override;
36  static vtkXMLTableWriter* New();
37 
39 
43  vtkSetMacro(NumberOfPieces, int);
44  vtkGetMacro(NumberOfPieces, int);
46 
48 
52  vtkSetMacro(WritePiece, int);
53  vtkGetMacro(WritePiece, int);
55 
61 
62 protected:
64  ~vtkXMLTableWriter() override;
65 
67 
68  vtkTable* GetInputAsTable();
69  const char* GetDataSetName() override; // vtkTable isn't a DataSet but it's used by vtkXMLWriter
70 
74  const char* GetDefaultFileExtension() override;
75 
76  void SetInputUpdateExtent(int piece, int numPieces);
77 
78  int WriteHeader();
79  int WriteAPiece();
80  int WriteFooter();
81 
82  void AllocatePositionArrays();
83  void DeletePositionArrays();
84 
85  int WriteInlineMode(vtkIndent indent);
86  void WriteInlinePieceAttributes();
87  void WriteInlinePiece(vtkIndent indent);
88 
89  void WriteAppendedPieceAttributes(int index);
90  void WriteAppendedPiece(int index, vtkIndent indent);
91  void WriteAppendedPieceData(int index);
92 
93  void WriteRowDataAppended(
94  vtkDataSetAttributes* ds, vtkIndent indent, OffsetsManagerGroup* dsManager);
95 
96  void WriteRowDataAppendedData(
97  vtkDataSetAttributes* ds, int timestep, OffsetsManagerGroup* pdManager);
98 
99  void WriteRowDataInline(vtkDataSetAttributes* ds, vtkIndent indent);
100 
105 
110 
114  vtkTypeInt64* NumberOfColsPositions;
115  vtkTypeInt64* NumberOfRowsPositions;
116 
121 
123 
124 private:
125  vtkXMLTableWriter(const vtkXMLTableWriter&) = delete;
126  void operator=(const vtkXMLTableWriter&) = delete;
127 };
128 
129 #endif
vtkXMLTableWriter::CurrentPiece
int CurrentPiece
Definition: vtkXMLTableWriter.h:122
vtkXMLWriter::GetDefaultFileExtension
virtual const char * GetDefaultFileExtension()=0
Get the default file extension for files written by this writer.
vtkDataSetAttributes
represent and manipulate attribute data in a dataset
Definition: vtkDataSetAttributes.h:53
vtkAlgorithm::FillInputPortInformation
virtual int FillInputPortInformation(int port, vtkInformation *info)
Fill the input port information objects for this algorithm.
vtkInformationVector
Store zero or more vtkInformation instances.
Definition: vtkInformationVector.h:35
vtkTable
A table, which contains similar-typed columns of data.
Definition: vtkTable.h:62
vtkXMLWriter.h
vtkXMLWriter::ProcessRequest
vtkTypeBool ProcessRequest(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector) override
Upstream/Downstream requests form the generalized interface through which executives invoke a algorit...
vtkXMLTableWriter::RowsOM
OffsetsManagerArray * RowsOM
For TimeStep support.
Definition: vtkXMLTableWriter.h:120
vtkXMLTableWriter::NumberOfColsPositions
vtkTypeInt64 * NumberOfColsPositions
Positions of attributes for each piece.
Definition: vtkXMLTableWriter.h:114
vtkX3D::port
@ port
Definition: vtkX3D.h:453
vtkXMLTableWriter::NumberOfRowsPositions
vtkTypeInt64 * NumberOfRowsPositions
Definition: vtkXMLTableWriter.h:115
vtkXMLWriter
Superclass for VTK's XML file writers.
Definition: vtkXMLWriter.h:61
vtkXMLTableWriter::WritePiece
int WritePiece
Which piece to write, if not all.
Definition: vtkXMLTableWriter.h:109
vtkIndent
a simple class to control print indentation
Definition: vtkIndent.h:33
vtkXMLWriter::GetDataSetName
virtual const char * GetDataSetName()=0
OffsetsManagerGroup
Definition: vtkXMLOffsetsManager.h:107
vtkXMLTableWriter
Write VTK XML Table files.
Definition: vtkXMLTableWriter.h:31
vtkInformation
Store vtkAlgorithm input/output information.
Definition: vtkInformation.h:73
vtkX3D::info
@ info
Definition: vtkX3D.h:382
vtkAlgorithm::New
static vtkAlgorithm * New()
OffsetsManagerArray
Definition: vtkXMLOffsetsManager.h:154
vtkXMLTableWriter::NumberOfPieces
int NumberOfPieces
Number of pieces used for streaming.
Definition: vtkXMLTableWriter.h:104
vtkX3D::index
@ index
Definition: vtkX3D.h:252
vtkXMLWriter::PrintSelf
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
vtkTypeBool
int vtkTypeBool
Definition: vtkABI.h:69