GEOSX
VTKOutput.hpp
Go to the documentation of this file.
1 /*
2  * ------------------------------------------------------------------------------------------------------------
3  * SPDX-License-Identifier: LGPL-2.1-only
4  *
5  * Copyright (c) 2018-2020 Lawrence Livermore National Security LLC
6  * Copyright (c) 2018-2020 The Board of Trustees of the Leland Stanford Junior University
7  * Copyright (c) 2018-2020 Total, S.A
8  * Copyright (c) 2019- GEOSX Contributors
9  * All rights reserved
10  *
11  * See top level LICENSE, COPYRIGHT, CONTRIBUTORS, NOTICE, and ACKNOWLEDGEMENTS files for details.
12  * ------------------------------------------------------------------------------------------------------------
13  */
14 
19 #ifndef GEOSX_MANAGERS_OUTPUTS_VTKOUTPUT_HPP_
20 #define GEOSX_MANAGERS_OUTPUTS_VTKOUTPUT_HPP_
21 
22 #include "OutputBase.hpp"
23 #include "fileIO/vtk/VTKPolyDataWriterInterface.hpp"
24 
25 
26 namespace geosx
27 {
28 
34 class VTKOutput : public OutputBase
35 {
36 public:
38 
39  VTKOutput( std::string const & name, Group * const parent );
40 
42  virtual ~VTKOutput() override;
43 
48  static string CatalogName() { return "VTK"; }
49 
54  virtual void Execute( real64 const time_n,
55  real64 const dt,
56  integer const cycleNumber,
57  integer const eventCounter,
58  real64 const eventProgress,
59  dataRepository::Group * domain ) override;
60 
65  virtual void Cleanup( real64 const time_n,
66  integer const cycleNumber,
67  integer const eventCounter,
68  real64 const eventProgress,
69  dataRepository::Group * domain ) override
70  {
71  Execute( time_n, 0, cycleNumber, eventCounter, eventProgress, domain );
72  }
73 
75  struct viewKeysStruct : OutputBase::viewKeysStruct
76  {
77  static constexpr auto plotFileRoot = "plotFileRoot";
78  static constexpr auto writeFEMFaces = "writeFEMFaces";
79  static constexpr auto plotLevel = "plotLevel";
80  static constexpr auto binaryString = "writeBinaryData";
81 
82  } vtkOutputViewKeys;
84 
85 private:
86  string m_plotFileRoot;
87  integer m_writeFaceMesh;
88  integer m_plotLevel;
89 
90  integer m_writeBinaryData;
91 
93 
94 };
95 
96 
97 } /* namespace geosx */
98 
99 #endif /* GEOSX_MANAGERS_OUTPUTS_VTKOUTPUT_HPP_ */
virtual ~VTKOutput() override
Destructor.
double real64
64-bit floating point type.
Definition: DataTypes.hpp:136
virtual void Execute(real64 const time_n, real64 const dt, integer const cycleNumber, integer const eventCounter, real64 const eventProgress, dataRepository::Group *domain) override
Writes out a set of vtk files.
Encapsulate output methods for vtk.
VTKOutput(std::string const &name, Group *const parent)
Constructor.
std::int32_t integer
Signed integer type.
Definition: DataTypes.hpp:122
static string CatalogName()
Catalog name interface.
Definition: VTKOutput.hpp:48
virtual void Cleanup(real64 const time_n, integer const cycleNumber, integer const eventCounter, real64 const eventProgress, dataRepository::Group *domain) override
Write one final set of vtk files as the code exits.
Definition: VTKOutput.hpp:65
std::string string
String type.
Definition: DataTypes.hpp:131
struct containing the view access keys to be bound with class data member