OpenM++ runtime library (libopenm)
openm::IRunBase Struct Referenceabstract

public interface to initialize model run and input parameters More...

Inheritance diagram for openm::IRunBase:
Collaboration diagram for openm::IRunBase:

Public Member Functions

virtual int parameterIdByName (const char *i_name) const =0
 return id of parameter by name
 
virtual int parameterSubCount (int i_paramId) const =0
 number of parameter sub-values
 
virtual int parameterSelfSubCount (int i_paramId) const =0
 number of parameter sub-values for current process
 
virtual int parameterSubValueIndex (int i_paramId, int i_subId) const =0
 return index of parameter sub-value in the storage array of sub-values
 
virtual bool isUseSubValue (int i_subId) const =0
 return true if sub-value used by current process
 
virtual void readParameter (const char *i_name, int i_subId, const std::type_info &i_type, size_t i_size, void *io_valueArr)=0
 read model parameter
 
- Public Member Functions inherited from openm::IRunOptions
virtual bool isOptionExist (const char *i_key) const noexcept=0
 return true if run option found by i_key in run_option table for the current run id.
 
virtual std::string strOption (const char *i_key, const std::string &i_default="") const noexcept=0
 return string value of run option by i_key or default value if not found.
 
virtual bool boolOption (const char *i_key) const noexcept=0
 return boolean value of run option by i_key or false if not found or value is not "yes", "1", "true" or empty "" string.
 
virtual int boolOptionToInt (const char *i_key) const noexcept=0
 search for boolean value of run option by i_key and return one of:
return 1 if key found and value is one of: "yes", "1", "true" or empty value,
return 0 if key found and value is one of: "no", "0", "false",
return -1 if key not found,
return -2 otherwise.
 
virtual int intOption (const char *i_key, int i_default) const noexcept=0
 return int value of run option by i_key or default if not found or can not be converted to int.
 
virtual long long longOption (const char *i_key, long long i_default) const noexcept=0
 return long value of run option by i_key or default if not found or can not be converted to long.
 
virtual double doubleOption (const char *i_key, double i_default) const noexcept=0
 return double value of run option by i_key or default if not found or can not be converted to double.
 
virtual std::vector< std::pair< std::string, std::string > > allOptions (void) const noexcept=0
 return a copy of all run options as [key, value] pairs, ordered by key.
 

Detailed Description

public interface to initialize model run and input parameters


The documentation for this struct was generated from the following files: