Closeable
, AutoCloseable
public final class StempelFilter extends TokenFilter
Note: the input to the stemming filter must already be in lower case, so you will need to use LowerCaseFilter or LowerCaseTokenizer farther down the Tokenizer chain in order for this to work properly!
AttributeSource.AttributeFactory, AttributeSource.State
Modifier and Type | Field | Description |
---|---|---|
static int |
DEFAULT_MIN_LENGTH |
Minimum length of input words to be processed.
|
input
Constructor | Description |
---|---|
StempelFilter(TokenStream in,
StempelStemmer stemmer) |
Create filter using the supplied stemming table.
|
StempelFilter(TokenStream in,
StempelStemmer stemmer,
int minLength) |
Create filter using the supplied stemming table.
|
Modifier and Type | Method | Description |
---|---|---|
boolean |
incrementToken() |
Returns the next input Token, after being stemmed
|
addAttribute, addAttributeImpl, captureState, clearAttributes, cloneAttributes, copyTo, equals, getAttribute, getAttributeClassesIterator, getAttributeFactory, getAttributeImplsIterator, hasAttribute, hasAttributes, hashCode, reflectAsString, reflectWith, restoreState, toString
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
close, end, reset
public static final int DEFAULT_MIN_LENGTH
public StempelFilter(TokenStream in, StempelStemmer stemmer)
in
- input token streamstemmer
- stemmerpublic StempelFilter(TokenStream in, StempelStemmer stemmer, int minLength)
in
- input token streamstemmer
- stemmerminLength
- For performance reasons words shorter than minLength
characters are not processed, but simply returned.public boolean incrementToken() throws IOException
incrementToken
in class TokenStream
IOException
Copyright © 2000-2018 Apache Software Foundation. All Rights Reserved.