Пример #1
0
        public INode Get(char letter)
        {
            RandomNode node = cache.Get(firstChild);

            while (node != null)
            {
                if (node.Letter == letter)
                {
                    return(node);
                }
                else
                {
                    node = cache.Get(node.nextSibling);
                }
            }
            return(null);
        }
Пример #2
0
 public NodeCache(string filename)
 {
     file   = new FileStream(filename, FileMode.Open, FileAccess.Read);
     reader = new BinaryReader(file, Encoding.UTF32);
     root   = Read(0);
 }