/// <summary> /// 得到配置信息 /// </summary> /// <param name="key">键</param> /// <returns>值</returns> public static string GetConfigDic(string key) { if (ConfigDic == null) { return(""); } if (ConfigDic.ContainsKey(key)) { return(ConfigDic[key]); } else { return(""); } }
/// <summary> /// 设置配置信息 /// </summary> /// <param name="key">键</param> /// <param name="value">值</param> public static void SetConfigDic(string key, string value) { if (ConfigDic == null) { ConfigDic = new Dictionary <string, string>(); } if (ConfigDic.ContainsKey(key)) { ConfigDic[key] = value; } else { ConfigDic.Add(key, value); } }