VTK  9.7.20261008
vtkXMLStructuredDataWriter.h
Go to the documentation of this file.
1// SPDX-FileCopyrightText: Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
2// SPDX-License-Identifier: BSD-3-Clause
10
11#ifndef vtkXMLStructuredDataWriter_h
12#define vtkXMLStructuredDataWriter_h
13
14#include "vtkIOXMLModule.h" // For export macro
15#include "vtkWrappingHints.h" // For VTK_MARSHALAUTO
16#include "vtkXMLWriter.h"
17
18VTK_ABI_NAMESPACE_BEGIN
20class vtkInformation;
22
24{
25public:
27 void PrintSelf(ostream& os, vtkIndent indent) override;
28
30
34 vtkSetMacro(NumberOfPieces, int);
35 vtkGetMacro(NumberOfPieces, int);
37
39
43 vtkSetMacro(WritePiece, int);
44 vtkGetMacro(WritePiece, int);
46
48
51 vtkSetMacro(GhostLevel, int);
52 vtkGetMacro(GhostLevel, int);
54
56
61 vtkSetVector6Macro(WriteExtent, int);
62 vtkGetVector6Macro(WriteExtent, int);
64
65protected:
68
69 // Writing drivers defined by subclasses.
70 void WritePrimaryElementAttributes(ostream& os, vtkIndent indent) override;
71 virtual void WriteAppendedPiece(int index, vtkIndent indent);
72 virtual void WriteAppendedPieceData(int index);
73 virtual void WriteInlinePiece(vtkIndent indent);
74 virtual void GetInputExtent(int* extent) = 0;
75
76 virtual int WriteHeader();
77 virtual int WriteAPiece();
78 virtual int WriteFooter();
79
80 virtual void AllocatePositionArrays();
81 virtual void DeletePositionArrays();
82
83 virtual int WriteInlineMode(vtkIndent indent);
85 VTK_FUTURE_CONST int extent[6], vtkIdType* increments, int i, int j, int k);
86 void CalculatePieceFractions(float* fractions);
87
88 void SetInputUpdateExtent(int piece);
90 vtkInformationVector* outputVector) override;
91
92 vtkSetVector6Macro(InternalWriteExtent, int);
93
95
96 // The extent of the input to write, as specified by user
98
99 // The actual extent of the input to write.
101
102 // Number of pieces used for streaming.
104
106
108
110
112
113 vtkTypeInt64* ExtentPositions;
114
115 // Appended data offsets of point and cell data arrays.
116 // Store offset position (add TimeStep support)
119
120private:
122 void operator=(const vtkXMLStructuredDataWriter&) = delete;
123};
124
125VTK_ABI_NAMESPACE_END
126#endif
Abstract superclass for all arrays.
abstract class to specify dataset behavior
Definition vtkDataSet.h:165
a simple class to control print indentation
Definition vtkIndent.h:108
Store zero or more vtkInformation instances.
Store vtkAlgorithm input/output information.
virtual void WriteAppendedPiece(int index, vtkIndent indent)
void WritePrimaryElementAttributes(ostream &os, vtkIndent indent) override
virtual void WriteAppendedPieceData(int index)
void CalculatePieceFractions(float *fractions)
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
virtual void DeletePositionArrays()
virtual void WriteInlinePiece(vtkIndent indent)
vtkIdType GetStartTuple(VTK_FUTURE_CONST int extent[6], vtkIdType *increments, int i, int j, int k)
virtual void AllocatePositionArrays()
virtual void GetInputExtent(int *extent)=0
static vtkIdType GetNumberOfValues(vtkDataSet *input)
~vtkXMLStructuredDataWriter() override
vtkTypeBool ProcessRequest(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector) override
Upstream/Downstream requests form the generalized interface through which executives invoke a algorit...
void SetInputUpdateExtent(int piece)
virtual int WriteInlineMode(vtkIndent indent)
int vtkTypeBool
Definition vtkABI.h:64
int vtkIdType
Definition vtkType.h:363
#define VTK_MARSHALAUTO