public final class GermanStemFilter extends TokenFilter
TokenFilter that stems German words.
It supports a table of words that should
not be stemmed at all. The stemmer used can be changed at runtime after the
filter object is created (as long as it is a GermanStemmer).
To prevent terms from being stemmed use an instance of
SetKeywordMarkerFilter or a custom TokenFilter that sets
the KeywordAttribute before this TokenStream.
SetKeywordMarkerFilterAttributeSource.StateinputDEFAULT_TOKEN_ATTRIBUTE_FACTORY| Constructor and Description |
|---|
GermanStemFilter(TokenStream in)
Creates a
GermanStemFilter instance |
| Modifier and Type | Method and Description |
|---|---|
boolean |
incrementToken() |
void |
setStemmer(GermanStemmer stemmer)
Set a alternative/custom
GermanStemmer for this filter. |
close, end, resetaddAttribute, addAttributeImpl, captureState, clearAttributes, cloneAttributes, copyTo, equals, getAttribute, getAttributeClassesIterator, getAttributeFactory, getAttributeImplsIterator, hasAttribute, hasAttributes, hashCode, reflectAsString, reflectWith, removeAllAttributes, restoreState, toStringpublic GermanStemFilter(TokenStream in)
GermanStemFilter instancein - the source TokenStreampublic boolean incrementToken()
throws IOException
incrementToken in class TokenStreamIOExceptionpublic void setStemmer(GermanStemmer stemmer)
GermanStemmer for this filter.Copyright © 2000-2016 Apache Software Foundation. All Rights Reserved.