VTK  9.0.1
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 
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 */
Superclass for algorithms that produce only data object as output.
general representation of visualization data
Definition: vtkDataObject.h:60
dynamic, self-adjusting array of double
a simple class to control print indentation
Definition: vtkIndent.h:34
Store zero or more vtkInformation instances.
Store vtkAlgorithm input/output information.
write eXtensible Data Model and Format files
int RequestUpdateExtent(vtkInformation *, vtkInformationVector **, vtkInformationVector *) override
This is called by the superclass.
~vtkXdmf3Writer() override
static vtkXdmf3Writer * New()
vtkDataObject * OriginalInput
void WriteDataInternal(vtkInformation *request)
int RequestInformation(vtkInformation *, vtkInformationVector **, vtkInformationVector *) override
void SetGhostLevel(int)
We never write out ghost cells.
virtual int CheckParameters()
virtual int GlobalContinueExecuting(int localContinueExecution)
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
int CheckParametersInternal(int NumberOfProcesses, int MyRank)
virtual void SetInputData(vtkDataObject *dobj)
Set the input data set.
virtual int Write()
Write data to output.
int RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *) override
vtkDoubleArray * TimeValues
unsigned int LightDataLimit