org.apache.lucene.facet.index.streaming
Class CategoryTokenizerBase
java.lang.Object
org.apache.lucene.util.AttributeSource
org.apache.lucene.analysis.TokenStream
org.apache.lucene.analysis.TokenFilter
org.apache.lucene.facet.index.streaming.CategoryTokenizerBase
- All Implemented Interfaces:
- Closeable
- Direct Known Subclasses:
- CategoryListTokenizer, CategoryTokenizer
public abstract class CategoryTokenizerBase
- extends TokenFilter
A base class for all token filters which add term and payload attributes to
tokens and are to be used in CategoryDocumentBuilder
. Contains three
attributes: CategoryAttribute
, CharTermAttribute
and
PayloadAttribute
.
- WARNING: This API is experimental and might change in incompatible ways in the next release.
Methods inherited from class org.apache.lucene.util.AttributeSource |
addAttribute, addAttributeImpl, captureState, clearAttributes, cloneAttributes, copyTo, equals, getAttribute, getAttributeClassesIterator, getAttributeFactory, getAttributeImplsIterator, hasAttribute, hasAttributes, hashCode, reflectAsString, reflectWith, restoreState |
categoryAttribute
protected CategoryAttribute categoryAttribute
- The stream's category attributes.
payloadAttribute
protected PayloadAttribute payloadAttribute
- The stream's payload attribute.
termAttribute
protected CharTermAttribute termAttribute
- The stream's term attribute.
payload
protected BytesRef payload
- The object used for constructing payloads.
indexingParams
protected FacetIndexingParams indexingParams
- Indexing params for creating term text
CategoryTokenizerBase
public CategoryTokenizerBase(TokenStream input,
FacetIndexingParams indexingParams)
- Constructor.
- Parameters:
input
- The input stream, either CategoryParentsStream
or an
extension of CategoryTokenizerBase
.indexingParams
- The indexing params to use.
incrementToken
public abstract boolean incrementToken()
throws IOException
- Specified by:
incrementToken
in class TokenStream
- Throws:
IOException
Copyright © 2000-2012 Apache Software Foundation. All Rights Reserved.