FileDocCategorySizeDatePackage
CJKAnalyzer.javaAPI DocApache Lucene 1.92493Mon Feb 20 09:18:52 GMT 2006org.apache.lucene.analysis.cjk

CJKAnalyzer

public class CJKAnalyzer extends Analyzer
Filters CJKTokenizer with StopFilter.
author
Che, Dong

Fields Summary
public static final String[]
STOP_WORDS
An array containing some common English words that are not usually useful for searching and some double-byte interpunctions.
private Set
stopTable
stop word list
Constructors Summary
public CJKAnalyzer()
Builds an analyzer which removes words in {@link #STOP_WORDS}.


  //~ Constructors -----------------------------------------------------------

              
    
    stopTable = StopFilter.makeStopSet(STOP_WORDS);
  
public CJKAnalyzer(String[] stopWords)
Builds an analyzer which removes words in the provided array.

param
stopWords stop word array

    stopTable = StopFilter.makeStopSet(stopWords);
  
Methods Summary
public final org.apache.lucene.analysis.TokenStreamtokenStream(java.lang.String fieldName, java.io.Reader reader)
get token stream from input

param
fieldName lucene field name
param
reader input reader
return
TokenStream

    return new StopFilter(new CJKTokenizer(reader), stopTable);