A class that encapsulates the whole of the model.
More...
#include <Model.hpp>
|
enum | {
RESTARTFILE_KEY
, STARTTIME_KEY
, STOPTIME_KEY
, RUNLENGTH_KEY
,
TIMESTEP_KEY
, MISSINGVALUE_KEY
} |
|
typedef ConfigurationHelp::HelpMap | HelpMap |
|
using | ConfigType |
|
|
void | configure () override |
| The configuration function.
|
|
ConfigMap | getConfig () const |
|
void | run () |
| Run the model.
|
|
void | writeRestartFile () |
|
void | setFinalFilename (const std::string &finalFile) |
| Sets the filename of the restart file that would currently be written out.
|
|
ModelMetadata & | metadata () |
| Gets the model metadata instance.
|
|
const std::map< int, std::string > | keyMap |
|
const std::map< int, std::string > | keyMap |
|
const std::map< int, std::string > | keyMap |
|
const std::map< int, std::string > | keyMap |
|
virtual ConfigMap | getConfiguration () const |
| Returns the current configuration of the object.
|
|
|
static HelpMap & | getHelpText (HelpMap &map, bool getAll) |
|
static HelpMap & | getHelpRecursive (HelpMap &map, bool getAll) |
|
static T | getConfiguration (const std::string &name, const T &defaultValue) |
| Gets the value of the configuration with a given name from the default Configurator.
|
|
static void | tryConfigure (T &ref) |
| Template function for conditionally configuring references.
|
|
static void | tryConfigure (T *ptr) |
| Template function for conditionally configuring classes via a pointer.
|
|
static ConfigMap | tryGetConfiguration (T &ref) |
| Template function for conditionally retrieving class configuration via a reference.
|
|
static ConfigMap | tryGetConfiguration (T *ptr) |
| Template function for conditionally retrieving class configuration via a pointer.
|
|
static HelpMap & | getHelpText (HelpMap &map, bool getAll) |
| Gets the text to be printed as the help text for this configuration.
|
|
static HelpMap & | getHelpRecursive (HelpMap &map, bool getAll) |
| Gets the configuration help text for the current class as well as any classes used herein.
|
|
static void | clearConfigurationMap () |
| Clear the configuration map. Usually used only in test suites.
|
|
|
static const std::string | restartOptionName = "model.init_file" |
|
static const std::map< int, std::string > | keyMap |
| A per-class static map to provide compile-time checking of configuration keys.
|
|
|
void | addOption (const std::string &name, const T &defaultValue) |
| Adds an option to the per-class option map.
|
|
T | retrieveValue (const std::string &name) |
| Retrieves a configured value of a single option.
|
|
A class that encapsulates the whole of the model.
Definition at line 24 of file Model.hpp.
◆ anonymous enum
◆ Model()
Nextsim::Model::Model |
( |
| ) |
|
◆ ~Model()
Nextsim::Model::~Model |
( |
| ) |
|
◆ configure()
void Nextsim::Model::configure |
( |
| ) |
|
|
overridevirtual |
◆ getConfig()
ConfigMap Nextsim::Model::getConfig |
( |
| ) |
const |
◆ getHelpRecursive()
Model::HelpMap & Nextsim::Model::getHelpRecursive |
( |
HelpMap & | map, |
|
|
bool | getAll ) |
|
static |
◆ getHelpText()
Model::HelpMap & Nextsim::Model::getHelpText |
( |
HelpMap & | map, |
|
|
bool | getAll ) |
|
static |
◆ metadata()
Gets the model metadata instance.
Definition at line 146 of file Model.cpp.
◆ run()
void Nextsim::Model::run |
( |
| ) |
|
◆ writeRestartFile()
void Nextsim::Model::writeRestartFile |
( |
| ) |
|
◆ restartOptionName
const std::string Nextsim::Model::restartOptionName = "model.init_file" |
|
static |
The documentation for this class was generated from the following files: