コード例 #1
0
        public static void SaveEnvironment()
        {
            string fd = ContextGlobal.serialize();

            //DataFileUtils.savefile(fd, "context.txt");
            DataFileUtils.savefileZipped(fd, "context.zip");
            //  DataFileUtils.savefileZipped(fd, "context "+DateTime.Now.Ticks.ToString() + ".zip");

            File.Copy("context.zip", "context " + DateTime.Now.Ticks.ToString() + ".zip");
            //DataFileUtils.savefile(fd, "context" + DateTime.Now.Ticks.ToString() + ".txt");
            System.Media.SystemSounds.Asterisk.Play();
        }
コード例 #2
0
        public static void SaveEnvironment(bool guiExit)
        {
            if (guiExit)
            {
                CompressWords();
            }

            string fd = ContextGlobal.serialize();

            DataFileUtils.savefileZipped(fd, "context.zip");

            File.Copy("context.zip", "context " + DateTime.Now.Ticks.ToString() + ".zip");
            System.Media.SystemSounds.Asterisk.Play();
        }
コード例 #3
0
        public static void LoadEnvironment(string path)
        {
            string data = "";

            string zipdata = DataFileUtils.LoadSingleLineZipped(path);

            if (!string.IsNullOrEmpty(zipdata))
            {
                data = zipdata;
            }

            ContextGlobal = new opis();
            ContextGlobal.load(data);

            DeCompressWords();
        }
コード例 #4
0
        public static void LoadEnvironment(string path)
        {
            string data = "";

            string zipdata = DataFileUtils.LoadSingleLineZipped(path);

            //  string zipdata = DataFileUtils.LoadSingleLine(path);
            if (!string.IsNullOrEmpty(zipdata))
            {
                data = zipdata;
            }


            //dataOut = new string[100000];
            //datcou = 0;

            ContextGlobal = new opis();
            ContextGlobal.load(data);
        }