示例#1
0
        public static DlcBinaryFlags FromDlc(string dlc)
        {
            DlcBinaryFlags dlcBinary = new DlcBinaryFlags();

            dlcBinary.Read(dlc);
            return(dlcBinary);
        }
示例#2
0
        public static DlcBinaryFlags FromXml(string xml)
        {
            DlcBinaryFlags dlcBinary = new DlcBinaryFlags();

            dlcBinary.Import(XDocument.Load(xml));
            return(dlcBinary);
        }
示例#3
0
        private static void CommandLine(string[] args)
        {
            DlcBinaryFlags dlc;

            if ((args.Length == 2 || args.Length == 3) && args[0] == "-e")
            {
                dlc = new DlcBinaryFlags();
                if (args.Length == 3)
                {
                    dlc = DlcBinaryFlags.FromDlc(args[1]);
                }

                dlc.Export(args[2]);
            }
            else if (args.Length == 3 && args[0] == "-i")
            {
                dlc = DlcBinaryFlags.FromXml(args[1]);
                dlc.Write(args[2]);
            }
        }