/// <summary> /// 加载文件 /// </summary> /// <param name="filepath"></param> /// <returns></returns> public static RuleList LoadFile(string filepath) { string text = File.ReadAllText(filepath, Encoding.UTF8); var rl = RuleList.LoadString(text); return(rl ?? new RuleList()); }
private PacketManger() { RuleList = RuleList.LoadFile(); mDisabled = RuleList.Disabled; }