org.apache.lucene.analysis.standard

Class StandardAnalyzer

public class StandardAnalyzer extends Analyzer

Filters StandardTokenizer with StandardFilter, LowerCaseFilter and StopFilter, using a list of English stop words.

Version: $Id: StandardAnalyzer.java 219090 2005-07-14 20:36:28Z dnaber $

Field Summary
static String[]STOP_WORDS
An array containing some common English words that are usually not useful for searching.
Constructor Summary
StandardAnalyzer()
Builds an analyzer with the default stop words (STOP_WORDS).
StandardAnalyzer(Set stopWords)
Builds an analyzer with the given stop words.
StandardAnalyzer(String[] stopWords)
Builds an analyzer with the given stop words.
StandardAnalyzer(File stopwords)
Builds an analyzer with the stop words from the given file.
StandardAnalyzer(Reader stopwords)
Builds an analyzer with the stop words from the given reader.
Method Summary
TokenStreamtokenStream(String fieldName, Reader reader)
Constructs a StandardTokenizer filtered by a StandardFilter, a LowerCaseFilter and a StopFilter.

Field Detail

STOP_WORDS

public static final String[] STOP_WORDS
An array containing some common English words that are usually not useful for searching.

Constructor Detail

StandardAnalyzer

public StandardAnalyzer()
Builds an analyzer with the default stop words (STOP_WORDS).

StandardAnalyzer

public StandardAnalyzer(Set stopWords)
Builds an analyzer with the given stop words.

StandardAnalyzer

public StandardAnalyzer(String[] stopWords)
Builds an analyzer with the given stop words.

StandardAnalyzer

public StandardAnalyzer(File stopwords)
Builds an analyzer with the stop words from the given file.

See Also: getWordSet

StandardAnalyzer

public StandardAnalyzer(Reader stopwords)
Builds an analyzer with the stop words from the given reader.

See Also: getWordSet

Method Detail

tokenStream

public TokenStream tokenStream(String fieldName, Reader reader)
Constructs a StandardTokenizer filtered by a StandardFilter, a LowerCaseFilter and a StopFilter.
Copyright © 2000-2007 Apache Software Foundation. All Rights Reserved.