| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657 | using System;using System.Collections.Generic;using System.Text;using WCS.Entity;namespace WCS.Core{    public static class Configs    {        public static Type ProtocolProxyBaseType { get; set; }        private static List<SystemMode> SystemModes { get; set; } = new List<SystemMode>();        /// <summary>        /// 添加一种模式        /// </summary>        /// <param name="mode"></param>        public static void AddSystemMode(SystemMode mode)        {            if (SystemModes.Contains(mode)) return;            SystemModes.Add(mode);        }        /// <summary>        /// 是否有        /// </summary>        /// <param name="mode"></param>        /// <returns></returns>        public static bool Any(SystemMode mode)        {            return SystemModes.Contains(mode);        }        public static Encoding StringEncoding { get; set; }        public static Action<Action<WCS_CMD>> DoCmds { get; set; }        public static string DebugRedisUrl { get; set; }        public static event Action PublishEvent;        internal static void Publish()        {            PublishEvent?.Invoke();        }        public static Action<string, string> UploadException { get; set; }    }    /// <summary>    /// 系统模式    /// </summary>    public enum SystemMode    {        虚拟PLC = 1,    }}
 |