VTK  9.0.1
vtkXMLUnstructuredGridReader.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkXMLUnstructuredGridReader.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 =========================================================================*/
29 #ifndef vtkXMLUnstructuredGridReader_h
30 #define vtkXMLUnstructuredGridReader_h
31 
32 #include "vtkIOXMLModule.h" // For export macro
34 
36 class vtkIdTypeArray;
37 
39 {
40 public:
42  void PrintSelf(ostream& os, vtkIndent indent) override;
44 
46 
49  vtkUnstructuredGrid* GetOutput();
50  vtkUnstructuredGrid* GetOutput(int idx);
52 
53 protected:
55  ~vtkXMLUnstructuredGridReader() override;
56 
57  const char* GetDataSetName() override;
58  void GetOutputUpdateExtent(int& piece, int& numberOfPieces, int& ghostLevel) override;
59  void SetupOutputTotals() override;
60  void SetupPieces(int numPieces) override;
61  void DestroyPieces() override;
62 
63  void SetupOutputData() override;
64  int ReadPiece(vtkXMLDataElement* ePiece) override;
65  void SetupNextPiece() override;
66  int ReadPieceData() override;
67 
68  // Read a data array whose tuples correspond to cells.
69  int ReadArrayForCells(vtkXMLDataElement* da, vtkAbstractArray* outArray) override;
70 
71  // Get the number of cells in the given piece. Valid after
72  // UpdateInformation.
73  vtkIdType GetNumberOfCellsInPiece(int piece) override;
74 
75  int FillOutputPortInformation(int, vtkInformation*) override;
76 
77  // The index of the cell in the output where the current piece
78  // begins.
80 
81  // The Cells element for each piece.
84 
86  unsigned long CellsOffset;
87 
88 private:
90  void operator=(const vtkXMLUnstructuredGridReader&) = delete;
91 };
92 
93 #endif
vtkIdType
int vtkIdType
Definition: vtkType.h:338
vtkXMLUnstructuredDataReader::ReadPieceData
int ReadPieceData() override
vtkXMLUnstructuredDataReader::ReadPiece
int ReadPiece(vtkXMLDataElement *ePiece) override
vtkXMLUnstructuredDataReader::SetupNextPiece
virtual void SetupNextPiece()
vtkXMLUnstructuredGridReader::CellsOffset
unsigned long CellsOffset
Definition: vtkXMLUnstructuredGridReader.h:86
vtkXMLUnstructuredDataReader.h
vtkXMLUnstructuredDataReader::SetupPieces
void SetupPieces(int numPieces) override
vtkXMLUnstructuredGridReader::CellsTimeStep
int CellsTimeStep
Definition: vtkXMLUnstructuredGridReader.h:85
vtkXMLDataReader::ReadArrayForCells
virtual int ReadArrayForCells(vtkXMLDataElement *da, vtkAbstractArray *outArray)
vtkXMLUnstructuredDataReader::DestroyPieces
void DestroyPieces() override
vtkXMLUnstructuredDataReader
Superclass for unstructured data XML readers.
Definition: vtkXMLUnstructuredDataReader.h:37
vtkIndent
a simple class to control print indentation
Definition: vtkIndent.h:33
vtkXMLUnstructuredGridReader::CellElements
vtkXMLDataElement ** CellElements
Definition: vtkXMLUnstructuredGridReader.h:82
vtkXMLReader::GetDataSetName
virtual const char * GetDataSetName()=0
vtkXMLDataElement
Represents an XML element and those nested inside.
Definition: vtkXMLDataElement.h:36
vtkAbstractArray
Abstract superclass for all arrays.
Definition: vtkAbstractArray.h:75
vtkInformation
Store vtkAlgorithm input/output information.
Definition: vtkInformation.h:73
vtkAlgorithm::New
static vtkAlgorithm * New()
vtkXMLUnstructuredGridReader::StartCell
vtkIdType StartCell
Definition: vtkXMLUnstructuredGridReader.h:79
vtkIdTypeArray
dynamic, self-adjusting array of vtkIdType
Definition: vtkIdTypeArray.h:35
vtkXMLUnstructuredGridReader::NumberOfCells
vtkIdType * NumberOfCells
Definition: vtkXMLUnstructuredGridReader.h:83
vtkXMLUnstructuredDataReader::PrintSelf
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
vtkXMLUnstructuredDataReader::GetOutputUpdateExtent
virtual void GetOutputUpdateExtent(int &piece, int &numberOfPieces, int &ghostLevel)=0
vtkUnstructuredGrid
dataset represents arbitrary combinations of all possible cell types
Definition: vtkUnstructuredGrid.h:92
vtkXMLUnstructuredDataReader::SetupOutputTotals
virtual void SetupOutputTotals()
vtkXMLUnstructuredDataReader::SetupOutputData
void SetupOutputData() override
vtkXMLUnstructuredDataReader::GetNumberOfCellsInPiece
virtual vtkIdType GetNumberOfCellsInPiece(int piece)=0
vtkAlgorithm::FillOutputPortInformation
virtual int FillOutputPortInformation(int port, vtkInformation *info)
Fill the output port information objects for this algorithm.
vtkXMLUnstructuredGridReader
Read VTK XML UnstructuredGrid files.
Definition: vtkXMLUnstructuredGridReader.h:38