public final class SetKeywordMarkerFilter extends KeywordMarkerFilter
KeywordAttribute. Each token
contained in the provided set is marked as a keyword by setting
KeywordAttribute.setKeyword(boolean) to true.AttributeSource.StateinputDEFAULT_TOKEN_ATTRIBUTE_FACTORY| Constructor and Description |
|---|
SetKeywordMarkerFilter(TokenStream in,
CharArraySet keywordSet)
Create a new KeywordSetMarkerFilter, that marks the current token as a
keyword if the tokens term buffer is contained in the given set via the
KeywordAttribute. |
| Modifier and Type | Method and Description |
|---|---|
protected boolean |
isKeyword() |
incrementTokenclose, end, resetaddAttribute, addAttributeImpl, captureState, clearAttributes, cloneAttributes, copyTo, equals, getAttribute, getAttributeClassesIterator, getAttributeFactory, getAttributeImplsIterator, hasAttribute, hasAttributes, hashCode, reflectAsString, reflectWith, removeAllAttributes, restoreState, toStringpublic SetKeywordMarkerFilter(TokenStream in, CharArraySet keywordSet)
KeywordAttribute.in - TokenStream to filterkeywordSet - the keywords set to lookup the current termbufferprotected boolean isKeyword()
isKeyword in class KeywordMarkerFilterCopyright © 2000-2016 Apache Software Foundation. All Rights Reserved.