示例#1
0
        public void LoadDAWG()
        {
            string path = Path.Combine(_workDir, "forms.dawg");

            if (File.Exists(path))
            {
                DateTime start = DateTime.Now;
                _dawg = Dawg <FormInterpretations> .Load(File.Open(path, FileMode.Open), ReadPayload);

                Console.WriteLine("DAWG load time: {0}", DateTime.Now - start);
                Console.WriteLine("DAWG nodes: {0}", _dawg.GetNodeCount());
                Console.WriteLine("DAWG count {0}", _dawg.Count());
            }
            else
            {
                _rebuildDAWG(path);
            }
        }