X-Git-Url: https://gerrit.automotivelinux.org/gerrit/gitweb?a=blobdiff_plain;f=src%2Fconfig.hpp;h=43fb67eda4b1c93afe07838e5133c9da669247a8;hb=2357c437b260d0d8cb927e6878f1226bfafb9d0b;hp=8588d658b3c657727f8b133c1707d3a061e17323;hpb=d50188f726b15a0ae2777bf2d91ee88836feeac5;p=apps%2Fagl-service-windowmanager.git diff --git a/src/config.hpp b/src/config.hpp index 8588d65..43fb67e 100644 --- a/src/config.hpp +++ b/src/config.hpp @@ -20,30 +20,34 @@ #include #include -namespace wm { +namespace wm +{ -using std::experimental::optional; using std::experimental::nullopt; +using std::experimental::optional; -struct config { - typedef std::map map; +struct config +{ + typedef std::map map; - map cfg; + map cfg; - config(); + config(); - optional get_string(char const *s) { - auto i = this->cfg.find(s); - return i != this->cfg.end() ? optional(i->second) : nullopt; - } + optional get_string(char const *s) + { + auto i = this->cfg.find(s); + return i != this->cfg.end() ? optional(i->second) : nullopt; + } - optional get_int(char const *s) { - auto i = this->cfg.find(s); - return i != this->cfg.end() ? optional(std::stoi(i->second)) - : nullopt; - } + optional get_int(char const *s) + { + auto i = this->cfg.find(s); + return i != this->cfg.end() ? optional(std::stoi(i->second)) + : nullopt; + } }; -} // namespace wm +} // namespace wm -#endif // TMCAGLWM_CONFIG_HPP +#endif // TMCAGLWM_CONFIG_HPP