OGS
CreateCubicLawPermeability.cpp
Go to the documentation of this file.
1
11
12#include <limits>
13#include <string>
14
15#include "BaseLib/ConfigTree.h"
17#include "ParameterLib/Utils.h"
18
19namespace MaterialPropertyLib
20{
21std::unique_ptr<Property> createCubicLawPermeability(
22 BaseLib::ConfigTree const& config,
23 std::vector<std::unique_ptr<ParameterLib::ParameterBase>> const& parameters)
24{
26 config.checkConfigParameter("type", "CubicLawPermeability");
27 DBUG("Create CubicLaw Permeability model");
28
29 // Second access for storage.
31 auto property_name = config.peekConfigParameter<std::string>("name");
32
33 auto const fracture_aperture_name =
35 config.getConfigParameter<std::string>("fracture_aperture", "");
36
38 fracture_aperture_name == ""
39 ? nullptr
41 fracture_aperture_name, parameters, 0, nullptr);
42
43 return std::make_unique<CubicLawPermeability>(std::move(property_name), b);
44}
45} // namespace MaterialPropertyLib
void DBUG(fmt::format_string< Args... > fmt, Args &&... args)
Definition Logging.h:30
T peekConfigParameter(std::string const &param) const
T getConfigParameter(std::string const &param) const
void checkConfigParameter(std::string const &param, std::string_view const value) const
std::unique_ptr< Property > createCubicLawPermeability(BaseLib::ConfigTree const &config, std::vector< std::unique_ptr< ParameterLib::ParameterBase > > const &parameters)
OGS_NO_DANGLING Parameter< ParameterDataType > & findParameter(std::string const &parameter_name, std::vector< std::unique_ptr< ParameterBase > > const &parameters, int const num_components, MeshLib::Mesh const *const mesh=nullptr)
Definition Utils.h:102