Ejemplo n.º 1
0
		public override TokenStream ReusableTokenStream(System.String fieldName, System.IO.TextReader reader)
		{
			Tokenizer tokenizer = (Tokenizer) GetPreviousTokenStream();
			if (tokenizer == null)
			{
				tokenizer = new WhitespaceTokenizer(reader);
				SetPreviousTokenStream(tokenizer);
			}
			else
				tokenizer.Reset(reader);
			return tokenizer;
		}
Ejemplo n.º 2
0
        public override TokenStream ReusableTokenStream(System.String fieldName, System.IO.TextReader reader)
        {
            Tokenizer tokenizer = (Tokenizer)GetPreviousTokenStream();

            if (tokenizer == null)
            {
                tokenizer = new WhitespaceTokenizer(reader);
                SetPreviousTokenStream(tokenizer);
            }
            else
            {
                tokenizer.Reset(reader);
            }
            return(tokenizer);
        }