Beispiel #1
0
        public static WordDict LoadFrom(Stream input)
        {
            var decoder  = new DawgDecoder(Dawg.FILEVERSION);
            var dawg     = decoder.Decode(input);
            var wordUtil = new WordDict();

            foreach (var pair in dawg.MatchsPrefix(null))
            {
                wordUtil.AddInternal(pair.Key, pair.Value);
            }

            return(wordUtil);
        }
Beispiel #2
0
        public static WordDict LoadFrom(Stream input)
        {
            var decoder = new DawgDecoder(Dawg.FILEVERSION);
            var dawg = decoder.Decode(input);
            var wordUtil = new WordDict();

            foreach (var pair in dawg.MatchsPrefix(null))
            {
                wordUtil.AddInternal(pair.Key, pair.Value);
            }

            return wordUtil;
        }