Esempio n. 1
0
        /// <summary>
        /// 获取全部保存的服务器名称
        /// </summary>
        /// <returns></returns>
        private List <string> GetDbServerNameList()
        {
            List <string> dbServerList = new List <string>();

            string[] dbServerArr = iniFile.GetSectionValues("DbServerList");
            if (dbServerArr == null)
            {
                return(dbServerList);
            }
            dbServerList = dbServerArr.ToList();
            return(dbServerList);
        }
Esempio n. 2
0
 /// <summary>
 /// 获取工作日志列表
 /// </summary>
 private void GetWorkLogList()
 {
     txtWeekWorkLog.Text = "";
     string[] logArr = iniFile.GetSectionValues(WorkLogName);
     if (logArr != null)
     {
         foreach (var log in logArr)
         {
             txtWeekWorkLog.AppendText(log + "\r\n");
         }
     }
 }
Esempio n. 3
0
        public static EntityCache GetEntityCache()
        {
            EntityCache entityCache = new EntityCache();

            string[] dbCustomerArr = iniFile.GetSectionValues("EntityCache");
            if (dbCustomerArr == null)
            {
                return(null);
            }
            string jsonStr = string.Join("", dbCustomerArr);

            if (string.IsNullOrWhiteSpace(jsonStr))
            {
                return(null);
            }
            entityCache = StringHelper.ToObject <EntityCache>(jsonStr);
            return(entityCache);
        }