Class ParaGridIO¶
Defined in File ParaGridIO.hpp
Inheritance Relationships¶
Base Type¶
public Nextsim::ParametricGrid::IParaGridIO(Class ParametricGrid::IParaGridIO)
Class Documentation¶
-
class ParaGridIO : public Nextsim::ParametricGrid::IParaGridIO¶
A class to perform input and output for the ParametricGrid class. unlike the other GridIO classes, this will hold non-restart files open to accumulate data until closed using the close function.
Public Functions
-
ParaGridIO(ParametricGrid &grid)¶
-
virtual ~ParaGridIO()¶
-
virtual ModelState getModelState(const std::string &filePath) override¶
Retrieves the ModelState from a restart file of the parametric_grid type.
- Parameters:
filePath – The file path containing the file to be read.
-
virtual void dumpModelState(const ModelState &state, const std::string &filePath) override¶
Writes the ModelState to a given file location from the provided model data.
@params state The model state and configuration object. creation model time). @params filePath The path for the restart file.
-
inline virtual ModelState readForcingTime(const std::set<std::string> &forcings, const TimePoint &time, const std::string &filePath) override¶
Reads forcings from a ParameticGrid flavoured file.
- Parameters:
forcings – The names of the forcings required.
time – The time for which to get the forcings.
filePath – Path to the file to read.
-
virtual void writeDiagnosticTime(const ModelState &state, const std::string &filePath) override¶
Writes diagnostic data to a file.
- Parameters:
state – The state to write to the file.
filePath – Path of the file to write to.
-
ParaGridIO(ParametricGrid &grid)¶