Пример #1
0
        /// <summary>
        /// 将各种属性转换成字符串
        /// </summary>
        /// <returns>属性字符串</returns>
        public override string ToString()
        {
            StringBuilder sb = new StringBuilder();

            sb.AppendLine("[USER="******"|1]");
            sb.AppendLine("Password=" + _Password);
            sb.Append(_PropertyList.ToString());

            return(sb.ToString());
        }
Пример #2
0
        /// <summary>
        /// 返回用户配置信息
        /// </summary>
        /// <returns></returns>
        private string GetMainDomainUserConfig()
        {
            StringBuilder sb = new StringBuilder();

            sb.Append(MainDomainConfigWithoutUserConfig.ToString());

            int count = 1;

            foreach (var o in FtpUserList)
            {
                string userconfig = "User" + count.ToString() + "=" + o.Key + "|1|0";
                sb.AppendLine(userconfig);
                count++;
            }
            return(sb.ToString());
        }