GEOS
SiloOutput.hpp
Go to the documentation of this file.
1 /*
2  * ------------------------------------------------------------------------------------------------------------
3  * SPDX-License-Identifier: LGPL-2.1-only
4  *
5  * Copyright (c) 2016-2024 Lawrence Livermore National Security LLC
6  * Copyright (c) 2018-2024 Total, S.A
7  * Copyright (c) 2018-2024 The Board of Trustees of the Leland Stanford Junior University
8  * Copyright (c) 2023-2024 Chevron
9  * Copyright (c) 2019- GEOS/GEOSX Contributors
10  * All rights reserved
11  *
12  * See top level LICENSE, COPYRIGHT, CONTRIBUTORS, NOTICE, and ACKNOWLEDGEMENTS files for details.
13  * ------------------------------------------------------------------------------------------------------------
14  */
15 
20 #ifndef GEOS_FILEIO_OUTPUTS_SILOOUTPUT_HPP_
21 #define GEOS_FILEIO_OUTPUTS_SILOOUTPUT_HPP_
22 
23 #include "OutputBase.hpp"
24 
25 
26 namespace geos
27 {
28 
34 class SiloOutput : public OutputBase
35 {
36 public:
38  SiloOutput( string const & name,
39  Group * const parent );
40 
42  virtual ~SiloOutput() override;
43 
48  static string catalogName() { return "Silo"; }
49 
54  virtual bool execute( real64 const time_n,
55  real64 const dt,
56  integer const cycleNumber,
57  integer const eventCounter,
58  real64 const eventProgress,
59  DomainPartition & domain ) override;
60 
65  virtual void cleanup( real64 const time_n,
66  integer const cycleNumber,
67  integer const eventCounter,
68  real64 const eventProgress,
69  DomainPartition & 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 writeEdgeMesh = "writeEdgeMesh";
79  static constexpr auto writeFaceMesh = "writeFEMFaces";
80  static constexpr auto writeCellElementMesh = "writeCellElementMesh";
81  static constexpr auto writeFaceElementMesh = "writeFaceElementMesh";
82  static constexpr auto plotLevel = "plotLevel";
83  static constexpr auto onlyPlotSpecifiedFieldNames = "onlyPlotSpecifiedFieldNames";
84  static constexpr auto fieldNames = "fieldNames";
85  } siloOutputViewKeys;
87 
88 private:
89 
90  void postInputInitialization() override;
91 
92  string m_plotFileRoot;
93  integer m_writeEdgeMesh;
94  integer m_writeFaceMesh;
95  integer m_writeCellElementMesh;
96  integer m_writeFaceElementMesh;
97  integer m_plotLevel;
98 
100  integer m_onlyPlotSpecifiedFieldNames;
101 
103  array1d< string > m_fieldNames;
104 
105 };
106 
107 
108 } /* namespace geos */
109 
110 #endif /* GEOS_FILEIO_OUTPUTS_SILOOUTPUT_HPP_ */
Partition of the decomposed physical domain. It also manages the connexion information to its neighbo...
SiloOutput(string const &name, Group *const parent)
Constructor.
static string catalogName()
Catalog name interface.
Definition: SiloOutput.hpp:48
virtual bool execute(real64 const time_n, real64 const dt, integer const cycleNumber, integer const eventCounter, real64 const eventProgress, DomainPartition &domain) override
Writes out a Silo plot file.
virtual ~SiloOutput() override
Destructor.
virtual void cleanup(real64 const time_n, integer const cycleNumber, integer const eventCounter, real64 const eventProgress, DomainPartition &domain) override
Writes out a Silo plot file at the end of the simulation.
Definition: SiloOutput.hpp:65
double real64
64-bit floating point type.
Definition: DataTypes.hpp:99
std::int32_t integer
Signed integer type.
Definition: DataTypes.hpp:82
struct containing the view access keys to be bound with class data member