OGS
TimeInterval.cpp
Go to the documentation of this file.
1
15
#include "
TimeInterval.h
"
16
17
#include <memory>
18
19
#include "
ConfigTree.h
"
20
21
namespace
BaseLib
22
{
23
TimeInterval
createTimeInterval
(
ConfigTree
const
& config)
24
{
26
auto
const
& time_interval_config = config.
getConfigSubtree
(
"time_interval"
);
27
28
const
auto
start_time =
30
time_interval_config.
getConfigParameter
<
double
>(
"start"
);
31
32
const
auto
end_time =
34
time_interval_config.getConfigParameter<
double
>(
"end"
);
35
36
return
{start_time, end_time};
37
}
38
}
// namespace BaseLib
ConfigTree.h
TimeInterval.h
BaseLib::ConfigTree
Definition
ConfigTree.h:107
BaseLib::ConfigTree::getConfigParameter
T getConfigParameter(std::string const ¶m) const
Definition
ConfigTree-impl.h:41
BaseLib::ConfigTree::getConfigSubtree
ConfigTree getConfigSubtree(std::string const &root) const
Definition
ConfigTree.cpp:162
BaseLib
Definition
TestDefinition.h:21
BaseLib::createTimeInterval
TimeInterval createTimeInterval(ConfigTree const &config)
Definition
TimeInterval.cpp:23
BaseLib::TimeInterval
Definition
TimeInterval.h:24
BaseLib
TimeInterval.cpp
Generated by
1.12.0