edu.mayo.informatics.indexer.lucene.filters
Class SnowballFilter

java.lang.Object
  extended by org.apache.lucene.analysis.TokenStream
      extended by org.apache.lucene.analysis.TokenFilter
          extended by edu.mayo.informatics.indexer.lucene.filters.SnowballFilter

public final class SnowballFilter
extends org.apache.lucene.analysis.TokenFilter

Normalizes token text with Snowball Stemmer - optionally keeping the origional terms.

Version:
$Id: NormFilter.java,v 1.1 2005/08/22 21:39:04 armbrust Exp $

Field Summary
 
Fields inherited from class org.apache.lucene.analysis.TokenFilter
input
 
Constructor Summary
SnowballFilter(java.lang.String snowballName, org.apache.lucene.analysis.TokenStream in, boolean keepOrigionalToken)
           
 
Method Summary
 org.apache.lucene.analysis.Token next()
          This implementation calls stem on every term, and then adds stems's results to the position of the term.
 
Methods inherited from class org.apache.lucene.analysis.TokenFilter
close, reset
 
Methods inherited from class org.apache.lucene.analysis.TokenStream
next
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SnowballFilter

public SnowballFilter(java.lang.String snowballName,
                      org.apache.lucene.analysis.TokenStream in,
                      boolean keepOrigionalToken)
Method Detail

next

public final org.apache.lucene.analysis.Token next()
                                            throws java.io.IOException
This implementation calls stem on every term, and then adds stems's results to the position of the term. If keepOrigionalToken is set in the constructor, then it also keeps the non-normed token in the token stream.

Overrides:
next in class org.apache.lucene.analysis.TokenStream
Throws:
java.io.IOException

Copyright: (c) 2004-2006 Mayo Foundation for Medical Education and Research (MFMER). All rights reserved. MAYO, MAYO CLINIC, and the triple-shield Mayo logo are trademarks and service marks of MFMER.