OutputWriter.hpp
Go to the documentation of this file.
1 /*
2  Copyright (c) 2013 Uni Research AS
3 
4  This file is part of the Open Porous Media project (OPM).
5 
6  OPM is free software: you can redistribute it and/or modify
7  it under the terms of the GNU General Public License as published by
8  the Free Software Foundation, either version 3 of the License, or
9  (at your option) any later version.
10 
11  OPM is distributed in the hope that it will be useful,
12  but WITHOUT ANY WARRANTY; without even the implied warranty of
13  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14  GNU General Public License for more details.
15 
16  You should have received a copy of the GNU General Public License
17  along with OPM. If not, see <http://www.gnu.org/licenses/>.
18 */
19 
20 #ifndef OPM_OUTPUT_WRITER_HPP
21 #define OPM_OUTPUT_WRITER_HPP
22 
23 #include <memory> // unique_ptr, shared_ptr
25 
26 struct UnstructuredGrid;
27 
28 namespace Opm {
29 
30 // forward declaration
31 class EclipseState;
32 namespace parameter { class ParameterGroup; }
33 class SimulatorState;
34 class WellState;
35 struct PhaseUsage;
36 
61 class OutputWriter {
62 public:
68  virtual ~OutputWriter () { }
69 
76  virtual void writeInit(const SimulatorTimerInterface &timer) = 0;
77 
89  virtual void writeTimeStep(const SimulatorTimerInterface& timer,
90  const SimulatorState& reservoirState,
91  const WellState& wellState,
92  bool isSubstep) = 0;
93 
109  static std::unique_ptr <OutputWriter>
110  create (const parameter::ParameterGroup& params,
111  std::shared_ptr <const EclipseState> eclipseState,
112  const Opm::PhaseUsage &phaseUsage,
113  std::shared_ptr <const UnstructuredGrid> grid);
114 };
115 
116 } // namespace Opm
117 
118 #endif /* OPM_OUTPUT_WRITER_HPP */
Definition: grid.h:98
Definition: AnisotropicEikonal.hpp:43
virtual void writeTimeStep(const SimulatorTimerInterface &timer, const SimulatorState &reservoirState, const WellState &wellState, bool isSubstep)=0
Write a blackoil reservoir state to disk for later inspection with visualization tools like ResInsigh...
virtual void writeInit(const SimulatorTimerInterface &timer)=0
Definition: ParameterGroup.hpp:109
Definition: SimulatorState.hpp:16
virtual ~OutputWriter()
Definition: OutputWriter.hpp:68
Definition: OutputWriter.hpp:61
The state of a set of wells.
Definition: WellState.hpp:36
static std::unique_ptr< OutputWriter > create(const parameter::ParameterGroup &params, std::shared_ptr< const EclipseState > eclipseState, const Opm::PhaseUsage &phaseUsage, std::shared_ptr< const UnstructuredGrid > grid)
Interface class for SimulatorTimer objects, to be improved.
Definition: SimulatorTimerInterface.hpp:33
const UnstructuredGrid & grid
Definition: ColumnExtract.hpp:31
Definition: BlackoilPhases.hpp:36