org.apache.lucene.analysis.cjk
Class CJKAnalyzer

java.lang.Object
  extended by org.apache.lucene.analysis.Analyzer
      extended by org.apache.lucene.analysis.ReusableAnalyzerBase
          extended by org.apache.lucene.analysis.StopwordAnalyzerBase
              extended by org.apache.lucene.analysis.cjk.CJKAnalyzer
All Implemented Interfaces:
Closeable

public final class CJKAnalyzer
extends org.apache.lucene.analysis.StopwordAnalyzerBase

An Analyzer that tokenizes text with CJKTokenizer and filters with StopFilter


Nested Class Summary
 
Nested classes/interfaces inherited from class org.apache.lucene.analysis.ReusableAnalyzerBase
org.apache.lucene.analysis.ReusableAnalyzerBase.TokenStreamComponents
 
Field Summary
static String[] STOP_WORDS
          Deprecated. use getDefaultStopSet() instead
 
Fields inherited from class org.apache.lucene.analysis.StopwordAnalyzerBase
matchVersion, stopwords
 
Constructor Summary
CJKAnalyzer(org.apache.lucene.util.Version matchVersion)
          Builds an analyzer which removes words in getDefaultStopSet().
CJKAnalyzer(org.apache.lucene.util.Version matchVersion, Set<?> stopwords)
          Builds an analyzer with the given stop words
CJKAnalyzer(org.apache.lucene.util.Version matchVersion, String... stopWords)
          Deprecated. use CJKAnalyzer(Version, Set) instead
 
Method Summary
protected  org.apache.lucene.analysis.ReusableAnalyzerBase.TokenStreamComponents createComponents(String fieldName, Reader reader)
           
static Set<?> getDefaultStopSet()
          Returns an unmodifiable instance of the default stop-words set.
 
Methods inherited from class org.apache.lucene.analysis.StopwordAnalyzerBase
getStopwordSet, loadStopwordSet
 
Methods inherited from class org.apache.lucene.analysis.ReusableAnalyzerBase
initReader, reusableTokenStream, tokenStream
 
Methods inherited from class org.apache.lucene.analysis.Analyzer
close, getOffsetGap, getPositionIncrementGap, getPreviousTokenStream, setPreviousTokenStream
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

STOP_WORDS

@Deprecated
public static final String[] STOP_WORDS
Deprecated. use getDefaultStopSet() instead
An array containing some common English words that are not usually useful for searching and some double-byte interpunctions.

Constructor Detail

CJKAnalyzer

public CJKAnalyzer(org.apache.lucene.util.Version matchVersion)
Builds an analyzer which removes words in getDefaultStopSet().


CJKAnalyzer

public CJKAnalyzer(org.apache.lucene.util.Version matchVersion,
                   Set<?> stopwords)
Builds an analyzer with the given stop words

Parameters:
matchVersion - lucene compatibility version
stopwords - a stopword set

CJKAnalyzer

@Deprecated
public CJKAnalyzer(org.apache.lucene.util.Version matchVersion,
                              String... stopWords)
Deprecated. use CJKAnalyzer(Version, Set) instead

Builds an analyzer which removes words in the provided array.

Parameters:
stopWords - stop word array
Method Detail

getDefaultStopSet

public static Set<?> getDefaultStopSet()
Returns an unmodifiable instance of the default stop-words set.

Returns:
an unmodifiable instance of the default stop-words set.

createComponents

protected org.apache.lucene.analysis.ReusableAnalyzerBase.TokenStreamComponents createComponents(String fieldName,
                                                                                                 Reader reader)
Specified by:
createComponents in class org.apache.lucene.analysis.ReusableAnalyzerBase


Copyright © 2000-2011 Apache Software Foundation. All Rights Reserved.