Package org.apache.lucene.codecs.memory
Class FSTTermsReader.TermsReader.BaseTermsEnum
- java.lang.Object
-
- org.apache.lucene.index.TermsEnum
-
- org.apache.lucene.index.BaseTermsEnum
-
- org.apache.lucene.codecs.memory.FSTTermsReader.TermsReader.BaseTermsEnum
-
- All Implemented Interfaces:
BytesRefIterator
- Direct Known Subclasses:
FSTTermsReader.TermsReader.IntersectTermsEnum,FSTTermsReader.TermsReader.SegmentTermsEnum
- Enclosing class:
- FSTTermsReader.TermsReader
abstract class FSTTermsReader.TermsReader.BaseTermsEnum extends BaseTermsEnum
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.apache.lucene.index.TermsEnum
TermsEnum.SeekStatus
-
-
Field Summary
Fields Modifier and Type Field Description (package private) ByteArrayDataInputbytesReader(package private) FSTTermOutputs.TermDatameta(package private) BlockTermStatestate
-
Constructor Summary
Constructors Constructor Description BaseTermsEnum()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description (package private) abstract voiddecodeMetaData()Decodes metadata into customized term stateintdocFreq()Returns the number of documents containing the current term.ImpactsEnumimpacts(int flags)Return aImpactsEnum.longord()Returns ordinal position for current term.PostingsEnumpostings(PostingsEnum reuse, int flags)GetPostingsEnumfor the current term, with control over whether freqs, positions, offsets or payloads are required.voidseekExact(long ord)Seeks to the specified term by ordinal (position) as previously returned byTermsEnum.ord().TermStatetermState()Expert: Returns the TermsEnums internal state to position the TermsEnum without re-seeking the term dictionary.longtotalTermFreq()Returns the total number of occurrences of this term across all documents (the sum of the freq() for each doc that has this term).-
Methods inherited from class org.apache.lucene.index.BaseTermsEnum
attributes, seekExact, seekExact
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.apache.lucene.util.BytesRefIterator
next
-
-
-
-
Field Detail
-
state
final BlockTermState state
-
meta
FSTTermOutputs.TermData meta
-
bytesReader
ByteArrayDataInput bytesReader
-
-
Method Detail
-
decodeMetaData
abstract void decodeMetaData() throws java.io.IOExceptionDecodes metadata into customized term state- Throws:
java.io.IOException
-
termState
public TermState termState() throws java.io.IOException
Description copied from class:TermsEnumExpert: Returns the TermsEnums internal state to position the TermsEnum without re-seeking the term dictionary.NOTE: A seek by
TermStatemight not capture theAttributeSource's state. Callers must maintain theAttributeSourcestates separately- Overrides:
termStatein classBaseTermsEnum- Throws:
java.io.IOException- See Also:
TermState,TermsEnum.seekExact(BytesRef, TermState)
-
docFreq
public int docFreq() throws java.io.IOExceptionDescription copied from class:TermsEnumReturns the number of documents containing the current term. Do not call this when the enum is unpositioned.TermsEnum.SeekStatus.END.
-
totalTermFreq
public long totalTermFreq() throws java.io.IOExceptionDescription copied from class:TermsEnumReturns the total number of occurrences of this term across all documents (the sum of the freq() for each doc that has this term). Note that, like other term measures, this measure does not take deleted documents into account.- Specified by:
totalTermFreqin classTermsEnum- Throws:
java.io.IOException
-
postings
public PostingsEnum postings(PostingsEnum reuse, int flags) throws java.io.IOException
Description copied from class:TermsEnumGetPostingsEnumfor the current term, with control over whether freqs, positions, offsets or payloads are required. Do not call this when the enum is unpositioned. This method will not return null.NOTE: the returned iterator may return deleted documents, so deleted documents have to be checked on top of the
PostingsEnum.- Specified by:
postingsin classTermsEnum- Parameters:
reuse- pass a prior PostingsEnum for possible reuseflags- specifies which optional per-document values you require; seePostingsEnum.FREQS- Throws:
java.io.IOException
-
impacts
public ImpactsEnum impacts(int flags) throws java.io.IOException
Description copied from class:TermsEnumReturn aImpactsEnum.- Specified by:
impactsin classTermsEnum- Throws:
java.io.IOException- See Also:
TermsEnum.postings(PostingsEnum, int)
-
seekExact
public void seekExact(long ord) throws java.io.IOExceptionDescription copied from class:TermsEnumSeeks to the specified term by ordinal (position) as previously returned byTermsEnum.ord(). The target ord may be before or after the current ord, and must be within bounds.
-
-