org.apache.solr.analysis
Class RemoveDuplicatesTokenFilterFactory

java.lang.Object
  extended by org.apache.solr.analysis.BaseTokenFilterFactory
      extended by org.apache.solr.analysis.RemoveDuplicatesTokenFilterFactory
All Implemented Interfaces:
TokenFilterFactory

public class RemoveDuplicatesTokenFilterFactory
extends BaseTokenFilterFactory

Factory for RemoveDuplicatesTokenFilter.

 <fieldType name="text_rmdup" class="solr.TextField" positionIncrementGap="100">
   <analyzer>
     <tokenizer class="solr.WhitespaceTokenizerFactory"/>
     <filter class="solr.RemoveDuplicatesTokenFilterFactory"/>
   </analyzer>
 </fieldType>

Version:
$Id$

Field Summary
protected  Map<String,String> args
          The init args
protected  Version luceneMatchVersion
          the luceneVersion arg
 
Fields inherited from class org.apache.solr.analysis.BaseTokenFilterFactory
log
 
Constructor Summary
RemoveDuplicatesTokenFilterFactory()
           
 
Method Summary
protected  void assureMatchVersion()
          this method can be called in the TokenizerFactory.create(java.io.Reader) or TokenFilterFactory.create(org.apache.lucene.analysis.TokenStream) methods, to inform user, that for this factory a luceneMatchVersion is required
 RemoveDuplicatesTokenFilter create(TokenStream input)
          Transform the specified input TokenStream
 Map<String,String> getArgs()
           
protected  boolean getBoolean(String name, boolean defaultVal)
           
protected  boolean getBoolean(String name, boolean defaultVal, boolean useDefault)
           
protected  int getInt(String name)
           
protected  int getInt(String name, int defaultVal)
           
protected  int getInt(String name, int defaultVal, boolean useDefault)
           
protected  CharArraySet getSnowballWordSet(ResourceLoader loader, String wordFiles, boolean ignoreCase)
          same as getWordSet(ResourceLoader, String, boolean), except the input is in snowball format.
protected  CharArraySet getWordSet(ResourceLoader loader, String wordFiles, boolean ignoreCase)
           
 void init(Map<String,String> args)
           
protected  void warnDeprecated(String message)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.apache.solr.analysis.TokenFilterFactory
getArgs, init
 

Field Detail

args

protected Map<String,String> args
The init args


luceneMatchVersion

protected Version luceneMatchVersion
the luceneVersion arg

Constructor Detail

RemoveDuplicatesTokenFilterFactory

public RemoveDuplicatesTokenFilterFactory()
Method Detail

create

public RemoveDuplicatesTokenFilter create(TokenStream input)
Description copied from interface: TokenFilterFactory
Transform the specified input TokenStream


init

public void init(Map<String,String> args)

getArgs

public Map<String,String> getArgs()

assureMatchVersion

protected final void assureMatchVersion()
this method can be called in the TokenizerFactory.create(java.io.Reader) or TokenFilterFactory.create(org.apache.lucene.analysis.TokenStream) methods, to inform user, that for this factory a luceneMatchVersion is required


warnDeprecated

protected final void warnDeprecated(String message)

getInt

protected int getInt(String name)

getInt

protected int getInt(String name,
                     int defaultVal)

getInt

protected int getInt(String name,
                     int defaultVal,
                     boolean useDefault)

getBoolean

protected boolean getBoolean(String name,
                             boolean defaultVal)

getBoolean

protected boolean getBoolean(String name,
                             boolean defaultVal,
                             boolean useDefault)

getWordSet

protected CharArraySet getWordSet(ResourceLoader loader,
                                  String wordFiles,
                                  boolean ignoreCase)
                           throws IOException
Throws:
IOException

getSnowballWordSet

protected CharArraySet getSnowballWordSet(ResourceLoader loader,
                                          String wordFiles,
                                          boolean ignoreCase)
                                   throws IOException
same as getWordSet(ResourceLoader, String, boolean), except the input is in snowball format.

Throws:
IOException