OGS 6.2.0-97-g4a610c866
CreateFluidThermalConductivityModel.cpp
Go to the documentation of this file.
1 
15 
16 #include "BaseLib/Error.h"
17 #include "BaseLib/ConfigTree.h"
18 
21 
22 namespace MaterialLib
23 {
24 namespace Fluid
25 {
26 std::unique_ptr<FluidProperty> createFluidThermalConductivityModel(
27  BaseLib::ConfigTree const& config)
28 {
30  auto const type = config.getConfigParameter<std::string>("type");
31 
32  if (type == "Constant")
33  {
34  return std::make_unique<ConstantFluidProperty>(
36  config.getConfigParameter<double>("value"));
37  }
38  // TODO: add more models
39 
40  OGS_FATAL(
41  "The viscosity type %s is unavailable.\n"
42  "The available type is \n\tConstant\n",
43  type.data());
44 }
45 
46 } // namespace Fluid
47 } // namespace MaterialLib
T getConfigParameter(std::string const &param) const
A function for creating a thermal conductivity model for fluid.
#define OGS_FATAL(fmt,...)
Definition: Error.h:63
std::unique_ptr< FluidProperty > createFluidThermalConductivityModel(BaseLib::ConfigTree const &config)