Пример #1
0
        /**
         *
         * Construct a Scanner object, attached to a Tree and a PrefixTester object
         *
         * @param t
         *            Tree to use
         * @param prefix_tester
         *            PrefixTester to use
         */
        public Scanner(Tree t, PrefixTester prefix_tester,
                       PatternExpander pattern_expander, TreeLoader loader)

        {
            this.tree             = t;
            this.prefix_tester    = prefix_tester;
            this.pattern_expander = pattern_expander;
            this.loader           = loader;
        }
Пример #2
0
        public void Load(System.IO.TextReader reader, PatternExpander pattern_expander, String prefix, TreeFlag flag)

        {
            String line;

            while ((line = reader.ReadLine()) != null)

            {
                if (line.Length > 4)

                {
                    pattern_expander.add(prefix, line, flag);
                }
            }
        }