Package org.apache.lucene.index
Class SingleTermsEnum
java.lang.Object
org.apache.lucene.index.TermsEnum
org.apache.lucene.index.FilteredTermsEnum
org.apache.lucene.index.SingleTermsEnum
- All Implemented Interfaces:
BytesRefIterator
Subclass of FilteredTermsEnum for enumerating a single term.
For example, this can be used by MultiTermQuery
s that need only visit one term, but
want to preserve MultiTermQuery semantics such as MultiTermQuery.getRewriteMethod()
.
-
Nested Class Summary
Nested classes/interfaces inherited from class org.apache.lucene.index.FilteredTermsEnum
FilteredTermsEnum.AcceptStatus
Nested classes/interfaces inherited from class org.apache.lucene.index.TermsEnum
TermsEnum.SeekStatus
-
Field Summary
Fields inherited from class org.apache.lucene.index.FilteredTermsEnum
actualTerm, tenum
-
Constructor Summary
ConstructorDescriptionSingleTermsEnum
(TermsEnum tenum, BytesRef termText) Creates a newSingleTermsEnum
. -
Method Summary
Modifier and TypeMethodDescriptionprotected FilteredTermsEnum.AcceptStatus
Return if term is accepted, not accepted or the iteration should ended (and possibly seek).Methods inherited from class org.apache.lucene.index.FilteredTermsEnum
attributes, docFreq, impacts, next, nextSeekTerm, ord, postings, seekCeil, seekExact, seekExact, seekExact, setInitialSeekTerm, term, termState, totalTermFreq
-
Constructor Details
-
SingleTermsEnum
Creates a newSingleTermsEnum
.After calling the constructor the enumeration is already pointing to the term, if it exists.
-
-
Method Details
-
accept
Description copied from class:FilteredTermsEnum
Return if term is accepted, not accepted or the iteration should ended (and possibly seek).- Specified by:
accept
in classFilteredTermsEnum
-