VTK  9.0.20210121
vtkXdmf3Writer.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkXdmf3Writer.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 =========================================================================*/
15 
26 #ifndef vtkXdmf3Writer_h
27 #define vtkXdmf3Writer_h
28 
29 #include "vtkIOXdmf3Module.h" // For export macro
30 
31 #include "vtkDataObjectAlgorithm.h"
32 
33 class vtkDoubleArray;
34 
35 class VTKIOXDMF3_EXPORT vtkXdmf3Writer : public vtkDataObjectAlgorithm
36 {
37 public:
38  static vtkXdmf3Writer* New();
40  void PrintSelf(ostream& os, vtkIndent indent) override;
41 
45  virtual void SetInputData(vtkDataObject* dobj);
46 
48 
51  vtkSetStringMacro(FileName);
52  vtkGetStringMacro(FileName);
54 
56 
60  void SetGhostLevel(int) {}
61  int GetGhostLevel() { return 0; }
63 
69  virtual int Write();
70 
72 
76  vtkSetMacro(LightDataLimit, unsigned int);
77  vtkGetMacro(LightDataLimit, unsigned int);
79 
81 
86  vtkSetMacro(WriteAllTimeSteps, bool);
87  vtkGetMacro(WriteAllTimeSteps, bool);
88  vtkBooleanMacro(WriteAllTimeSteps, bool);
90 
91 protected:
93  ~vtkXdmf3Writer() override;
94 
95  // Overridden to set up automatic loop over time steps.
97  // Overridden to continue automatic loop over time steps.
99  // Write out the input data objects as XDMF and HDF output files.
101 
102  char* FileName;
103  unsigned int LightDataLimit;
106  int MyRank;
107 
110  void WriteDataInternal(vtkInformation* request);
111  int CheckParametersInternal(int numberOfProcesses, int myRank);
112  virtual int CheckParameters();
113  // If writing in parallel multiple time steps exchange after each time step
114  // if we should continue the execution. Pass local continueExecution as a
115  // parameter and return the global continueExecution.
116  virtual int GlobalContinueExecuting(int localContinueExecution);
117 
119 
120 private:
121  vtkXdmf3Writer(const vtkXdmf3Writer&) = delete;
122  void operator=(const vtkXdmf3Writer&) = delete;
123 
124  class Internals;
125  Internals* Internal;
126 };
127 
128 #endif /* vtkXdmf3Writer_h */
vtkXdmf3Writer::OriginalInput
vtkDataObject * OriginalInput
Definition: vtkXdmf3Writer.h:109
vtkXdmf3Writer::FileName
char * FileName
Definition: vtkXdmf3Writer.h:102
vtkDataObjectAlgorithm::PrintSelf
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
vtkXdmf3Writer::WriteAllTimeSteps
bool WriteAllTimeSteps
Definition: vtkXdmf3Writer.h:104
vtkXdmf3Writer::MyRank
int MyRank
Definition: vtkXdmf3Writer.h:106
vtkInformationVector
Store zero or more vtkInformation instances.
Definition: vtkInformationVector.h:35
vtkDataObjectAlgorithm
Superclass for algorithms that produce only data object as output.
Definition: vtkDataObjectAlgorithm.h:43
vtkXdmf3Writer
write eXtensible Data Model and Format files
Definition: vtkXdmf3Writer.h:35
vtkXdmf3Writer::SetGhostLevel
void SetGhostLevel(int)
We never write out ghost cells.
Definition: vtkXdmf3Writer.h:60
vtkXdmf3Writer::GetGhostLevel
int GetGhostLevel()
Definition: vtkXdmf3Writer.h:61
vtkDataObjectAlgorithm::RequestUpdateExtent
virtual int RequestUpdateExtent(vtkInformation *, vtkInformationVector **, vtkInformationVector *)
This is called by the superclass.
Definition: vtkDataObjectAlgorithm.h:111
vtkIndent
a simple class to control print indentation
Definition: vtkIndent.h:33
vtkXdmf3Writer::InitWriters
bool InitWriters
Definition: vtkXdmf3Writer.h:118
vtkInformation
Store vtkAlgorithm input/output information.
Definition: vtkInformation.h:73
vtkXdmf3Writer::NumberOfProcesses
int NumberOfProcesses
Definition: vtkXdmf3Writer.h:105
vtkDataObjectAlgorithm::New
static vtkDataObjectAlgorithm * New()
vtkDataObjectAlgorithm::SetInputData
void SetInputData(vtkDataObject *)
Assign a data object as input.
vtkDoubleArray
dynamic, self-adjusting array of double
Definition: vtkDoubleArray.h:35
vtkDataObjectAlgorithm::RequestData
virtual int RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *)
Definition: vtkDataObjectAlgorithm.h:116
vtkXdmf3Writer::LightDataLimit
unsigned int LightDataLimit
Definition: vtkXdmf3Writer.h:103
vtkDataObjectAlgorithm.h
vtkDataObjectAlgorithm::RequestInformation
virtual int RequestInformation(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector)
vtkDataObject
general representation of visualization data
Definition: vtkDataObject.h:59
vtkXdmf3Writer::TimeValues
vtkDoubleArray * TimeValues
Definition: vtkXdmf3Writer.h:108