Class STMergingTermsEnum.MultiSegmentsPostingsEnum
- java.lang.Object
-
- org.apache.lucene.search.DocIdSetIterator
-
- org.apache.lucene.index.PostingsEnum
-
- org.apache.lucene.codecs.uniformsplit.sharedterms.STMergingTermsEnum.MultiSegmentsPostingsEnum
-
- Enclosing class:
- STMergingTermsEnum
protected class STMergingTermsEnum.MultiSegmentsPostingsEnum extends PostingsEnum
Combines multiple segmentsPostingsEnumas a singlePostingsEnum, for one field and one term.This
PostingsEnumdoes not extendFilterLeafReader.FilterPostingsEnumbecause it updates the delegate for each segment.
-
-
Field Summary
Fields Modifier and Type Field Description protected intdocIdprotected MergeState.DocMapdocMapprotected PostingsEnumpostingsEnumprotected booleanpostingsEnumExhaustedprotected intpostingsFlagsprotected PostingsEnum[]reusablePostingsEnumsprotected intsegmentIndexprotected List<STUniformSplitTermsWriter.SegmentPostings>segmentPostingsList-
Fields inherited from class org.apache.lucene.index.PostingsEnum
ALL, FREQS, NONE, OFFSETS, PAYLOADS, POSITIONS
-
Fields inherited from class org.apache.lucene.search.DocIdSetIterator
NO_MORE_DOCS
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedMultiSegmentsPostingsEnum(int numSegments)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description intadvance(int target)longcost()intdocID()intendOffset()intfreq()BytesRefgetPayload()protected PostingsEnumgetPostings(STUniformSplitTermsWriter.SegmentPostings segmentPostings)intnextDoc()intnextPosition()protected voidreset(List<STUniformSplitTermsWriter.SegmentPostings> segmentPostingsList)Resets/reuse thisPostingsEnum.protected voidsetPostingFlags(int flags)intstartOffset()-
Methods inherited from class org.apache.lucene.index.PostingsEnum
featureRequested
-
Methods inherited from class org.apache.lucene.search.DocIdSetIterator
all, empty, range, slowAdvance
-
-
-
-
Field Detail
-
reusablePostingsEnums
protected final PostingsEnum[] reusablePostingsEnums
-
segmentPostingsList
protected List<STUniformSplitTermsWriter.SegmentPostings> segmentPostingsList
-
segmentIndex
protected int segmentIndex
-
postingsEnum
protected PostingsEnum postingsEnum
-
postingsEnumExhausted
protected boolean postingsEnumExhausted
-
docMap
protected MergeState.DocMap docMap
-
docId
protected int docId
-
postingsFlags
protected int postingsFlags
-
-
Method Detail
-
reset
protected void reset(List<STUniformSplitTermsWriter.SegmentPostings> segmentPostingsList)
Resets/reuse thisPostingsEnum.- Parameters:
segmentPostingsList- List of segment postings ordered by segment index.
-
setPostingFlags
protected void setPostingFlags(int flags)
-
freq
public int freq() throws IOException- Specified by:
freqin classPostingsEnum- Throws:
IOException
-
nextPosition
public int nextPosition() throws IOException- Specified by:
nextPositionin classPostingsEnum- Throws:
IOException
-
startOffset
public int startOffset() throws IOException- Specified by:
startOffsetin classPostingsEnum- Throws:
IOException
-
endOffset
public int endOffset() throws IOException- Specified by:
endOffsetin classPostingsEnum- Throws:
IOException
-
getPayload
public BytesRef getPayload() throws IOException
- Specified by:
getPayloadin classPostingsEnum- Throws:
IOException
-
docID
public int docID()
- Specified by:
docIDin classDocIdSetIterator
-
nextDoc
public int nextDoc() throws IOException- Specified by:
nextDocin classDocIdSetIterator- Throws:
IOException
-
getPostings
protected PostingsEnum getPostings(STUniformSplitTermsWriter.SegmentPostings segmentPostings) throws IOException
- Throws:
IOException
-
advance
public int advance(int target)
- Specified by:
advancein classDocIdSetIterator
-
cost
public long cost()
- Specified by:
costin classDocIdSetIterator
-
-