com.atlassian.jira.issue.index.analyzer
Class CJKAnalyzer

java.lang.Object
  extended by org.apache.lucene.analysis.Analyzer
      extended by com.atlassian.jira.issue.index.analyzer.CJKAnalyzer

public class CJKAnalyzer
extends org.apache.lucene.analysis.Analyzer

Filters CJKTokenizer with StopFilter.

Author:
Che, Dong

Field Summary
static String[] STOP_WORDS
          An array containing some common English words that are not usually useful for searching and some double-byte interpunctions.
 
Constructor Summary
CJKAnalyzer(boolean indexing)
          Builds an analyzer which removes words in STOP_WORDS.
 
Method Summary
 boolean isIndexing()
           
 org.apache.lucene.analysis.TokenStream tokenStream(String fieldName, Reader reader)
          get token stream from input
protected  org.apache.lucene.analysis.TokenStream wrapStreamForIndexing(org.apache.lucene.analysis.TokenStream result)
           
 
Methods inherited from class org.apache.lucene.analysis.Analyzer
getPositionIncrementGap
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

STOP_WORDS

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.

Constructor Detail

CJKAnalyzer

public CJKAnalyzer(boolean indexing)
Builds an analyzer which removes words in STOP_WORDS.

Method Detail

tokenStream

public final org.apache.lucene.analysis.TokenStream tokenStream(String fieldName,
                                                                Reader reader)
get token stream from input

Specified by:
tokenStream in class org.apache.lucene.analysis.Analyzer
Parameters:
fieldName - lucene field name
reader - input reader
Returns:
TokenStream

isIndexing

public boolean isIndexing()

wrapStreamForIndexing

protected org.apache.lucene.analysis.TokenStream wrapStreamForIndexing(org.apache.lucene.analysis.TokenStream result)


Copyright © 2002-2007 Atlassian. All Rights Reserved.