zoukankan      html  css  js  c++  java
  • mem

    void EnvConfigParser::ParseMemSetting(const nlohmann::json &content) {
      auto sys_setting = content.find(kSysSettings);
      if (sys_setting == content.end()) {
        MS_LOG(WARNING) << "The '" << kSysSettings << "' not exists. Please check the config file '" << config_file_
                        << "' set by 'env_config_path' in context.";
        return;
      }

      has_sys_setting_ = true;

      auto sys_enable = CheckJsonKeyExist(*sys_setting, kSysSettings, kSysEnable);
      if (sys_enable.has_value()) {
        ParseSysEnable(**sys_enable);
      }

    }
    void EnvConfigParser::ParseSysEnable(const nlohmann::json &content) {
      if (!content.is_boolean()) {
        MS_LOG(WARNING) << "Json parse failed. 'enable' in " << kSysSettings << " should be boolean."
                        << " Please check the config file '" << config_file_ << "' set by 'env_config_path' in context.";
        sys_enabled_ = false;
        return;
      }
      sys_enabled_ = content;
    }
    大悲无泪--大悟无言--大笑无声
  • 相关阅读:
    angularjs学习笔记一之显示数据,修改数据
    收藏/不再提醒
    CSS3动画
    Content-Type
    键盘快捷键
    url、href、src 详解
    关于docnment.write() 会清空原来的内容
    jq事件注意点
    echart的自适应
    键盘事件
  • 原文地址:https://www.cnblogs.com/dpf-learn/p/14611130.html
Copyright © 2011-2022 走看看