NGen
Loading...
Searching...
No Matches
models::bmi Namespace Reference

Namespaces

namespace  helper
 

Classes

class  AbstractCLibBmiAdapter
 
class  Bmi_Adapter
 Abstract adapter interface for C++ classes to interact with the essential aspects of external models that implement the BMI spec but that are written in some other programming language. More...
 
class  Bmi_C_Adapter
 An adapter class to serve as a C++ interface to the essential aspects of external models written in the C language that implement the BMI. More...
 
class  Bmi_Cpp_Adapter
 A thin wrapper class to provide convenience functions around raw BMI models written in C++, especially those loaded dynamically from libraries. More...
 

Functions

template<typename T >
std::vector< T > GetValue (Bmi_Adapter &model, const std::string &name)
 Copy values from a BMI model adapter and box them into a vector.
 

Function Documentation

◆ GetValue()

template<typename T >
std::vector< T > models::bmi::GetValue ( Bmi_Adapter & model,
const std::string & name )

Copy values from a BMI model adapter and box them into a vector.

Template Parameters
TType to cast data from the BMI model to
ABmi model type
Parameters
modelBmi model adapter that interfaces to
Template Parameters
Abmi
Parameters
nameBmi variable name to query the model for
Returns
std::vector<T> Copy of data from the BMI model for variable
Parameters
name

References models::bmi::Bmi_Adapter::get_analogous_cxx_type(), models::bmi::Bmi_Adapter::get_model_name(), bmi::Bmi::GetValue(), bmi::Bmi::GetVarItemsize(), bmi::Bmi::GetVarNbytes(), bmi::Bmi::GetVarType(), and models::bmi::helper::make_vector().

Referenced by realization::Bmi_Module_Formulation::get_values(), realization::Bmi_C_Formulation::get_var_value_as(), and realization::Bmi_Cpp_Formulation::get_var_value_as().