如果只是用于OPS-XML序列化,不需要override[Clone][Bind],从而使代码更加干净
示例#1
0
文件: TempletApi.cs 项目: noear/Weed3
        public static Templet getTempletByFile(string file)
        {
            var opsXml = File.ReadAllText(Config.DIR_TEMPLET + "/" + file, UTF8Encoding.UTF8);

            Templet temp = new Templet();
            XDom.Bind(temp, opsXml);

            return temp;
        }
示例#2
0
        public static Templet getTempletByFile(string file)
        {
            var opsXml = File.ReadAllText(Config.DIR_TEMPLET + "/" + file, UTF8Encoding.UTF8);

            Templet temp = new Templet();

            XDom.Bind(temp, opsXml);

            return(temp);
        }