VTK
vtkPDataSetReader.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkPDataSetReader.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 =========================================================================*/
26 #ifndef vtkPDataSetReader_h
27 #define vtkPDataSetReader_h
28 
29 #include "vtkIOParallelModule.h" // For export macro
30 #include "vtkDataSetAlgorithm.h"
31 
32 class vtkDataSet;
33 
34 class VTKIOPARALLEL_EXPORT vtkPDataSetReader : public vtkDataSetAlgorithm
35 {
36 public:
37  void PrintSelf(ostream& os, vtkIndent indent) override;
39  static vtkPDataSetReader *New();
40 
42 
45  vtkSetStringMacro(FileName);
46  vtkGetStringMacro(FileName);
48 
50 
54  vtkGetMacro(DataType, int);
56 
60  int CanReadFile(const char* filename);
61 
62 protected:
64  ~vtkPDataSetReader() override;
65 
66  int RequestDataObject(vtkInformation* request,
67  vtkInformationVector** inputVector,
68  vtkInformationVector* outputVector) override;
69  void ReadPVTKFileInformation(ifstream *fp,
70  vtkInformation* request,
71  vtkInformationVector** inputVector,
72  vtkInformationVector* outputVector);
73  void ReadVTKFileInformation(vtkInformation* request,
74  vtkInformationVector** inputVector,
75  vtkInformationVector* outputVector);
76 
79  vtkInformationVector*) override;
80 
83  vtkInformationVector*) override;
84  int PolyDataExecute(vtkInformation*,
87  int UnstructuredGridExecute(vtkInformation*,
90  int ImageDataExecute(vtkInformation*,
93  int StructuredGridExecute(vtkInformation*,
96 
97  void CoverExtent(int ext[6], int *pieceMask);
98 
99  vtkDataSet *CheckOutput();
100  void SetNumberOfPieces(int num);
101 
102  ifstream *OpenFile(const char *);
103 
104  int ReadXML(ifstream *file, char **block, char **param, char **value);
107  char *FileName;
108  int DataType;
112 
113 private:
114  vtkPDataSetReader(const vtkPDataSetReader&) = delete;
115  void operator=(const vtkPDataSetReader&) = delete;
116 };
117 
118 #endif
Store vtkAlgorithm input/output information.
abstract class to specify dataset behavior
Definition: vtkDataSet.h:62
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
a simple class to control print indentation
Definition: vtkIndent.h:39
virtual int RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *)
This is called within ProcessRequest when a request asks the algorithm to do its work.
virtual int RequestInformation(vtkInformation *, vtkInformationVector **, vtkInformationVector *)
This is called within ProcessRequest when a request asks for Information.
Store zero or more vtkInformation instances.
Superclass for algorithms that produce output of the same type as input.
virtual int RequestDataObject(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector)
This is called within ProcessRequest to when a request asks the algorithm to create empty output data...
Manages reading pieces of a data set.
static vtkDataSetAlgorithm * New()