1 #ifndef __PBIO_API__PBIO__CONFIG_H_ea7a1512540d47be8a7663a585bcf973
2 #define __PBIO_API__PBIO__CONFIG_H_ea7a1512540d47be8a7663a585bcf973
28 Config(
const std::string config_filepath);
35 Config(
const char*
const config_filepath);
65 const std::string parameter,
70 std::string config_filepath;
72 std::vector<std::pair<std::string, double> > key_value;
75 std::vector<char const*> &keys,
76 std::vector<double> &values)
const;
97 const std::string config_filepath) :
98 config_filepath(config_filepath)
106 const char*
const config_filepath) :
107 config_filepath(config_filepath)
114 const std::string parameter,
117 key_value.push_back(std::make_pair(parameter, value));
122 void Config::prepare(
123 std::vector<char const*> &keys,
124 std::vector<double> &values)
const
126 keys.resize(key_value.size());
127 values.resize(key_value.size());
129 for(
size_t i = 0; i < key_value.size(); ++i)
131 keys[i] = key_value[i].first.c_str();
132 values[i] = key_value[i].second;
142 #endif // __PBIO_API__PBIO__CONFIG_H_ea7a1512540d47be8a7663a585bcf973
Interface object for creating other interface objects.
Definition: FacerecService.h:64
A class used to override the configuration parameters at runtime.
Definition: Config.h:19
Config & overrideParameter(const std::string parameter, const double value)
Override the parameter value.
Definition: Config.h:113
Definition: FacerecService.mm:79
Config(const std::string config_filepath)
A constructor that takes the path to a configuration file.
Definition: Config.h:96