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
Combines multiple segments
PostingsEnum
as a single PostingsEnum
, for one field
and one term.
This PostingsEnum
does not extend FilterLeafReader.FilterPostingsEnum
because it updates the delegate
for each segment.
-
Field Summary
Modifier and TypeFieldDescriptionprotected int
protected MergeState.DocMap
protected PostingsEnum
protected boolean
protected int
protected final PostingsEnum[]
protected int
protected List<org.apache.lucene.codecs.uniformsplit.sharedterms.STUniformSplitTermsWriter.SegmentPostings>
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
-
Method Summary
Modifier and TypeMethodDescriptionint
advance
(int target) long
cost()
int
docID()
int
int
freq()
protected PostingsEnum
getPostings
(org.apache.lucene.codecs.uniformsplit.sharedterms.STUniformSplitTermsWriter.SegmentPostings segmentPostings) int
nextDoc()
int
protected void
reset
(List<org.apache.lucene.codecs.uniformsplit.sharedterms.STUniformSplitTermsWriter.SegmentPostings> segmentPostingsList) Resets/reuse thisPostingsEnum
.protected void
setPostingFlags
(int flags) int
Methods inherited from class org.apache.lucene.index.PostingsEnum
featureRequested
Methods inherited from class org.apache.lucene.search.DocIdSetIterator
all, empty, range, slowAdvance
-
Field Details
-
reusablePostingsEnums
-
segmentPostingsList
protected List<org.apache.lucene.codecs.uniformsplit.sharedterms.STUniformSplitTermsWriter.SegmentPostings> segmentPostingsList -
segmentIndex
protected int segmentIndex -
postingsEnum
-
postingsEnumExhausted
protected boolean postingsEnumExhausted -
docMap
-
docId
protected int docId -
postingsFlags
protected int postingsFlags
-
-
Constructor Details
-
MultiSegmentsPostingsEnum
protected MultiSegmentsPostingsEnum(int numSegments)
-
-
Method Details
-
reset
protected void reset(List<org.apache.lucene.codecs.uniformsplit.sharedterms.STUniformSplitTermsWriter.SegmentPostings> segmentPostingsList) Resets/reuse thisPostingsEnum
.- Parameters:
segmentPostingsList
- List of segment postings ordered by segment index.
-
setPostingFlags
protected void setPostingFlags(int flags) -
freq
- Specified by:
freq
in classPostingsEnum
- Throws:
IOException
-
nextPosition
- Specified by:
nextPosition
in classPostingsEnum
- Throws:
IOException
-
startOffset
- Specified by:
startOffset
in classPostingsEnum
- Throws:
IOException
-
endOffset
- Specified by:
endOffset
in classPostingsEnum
- Throws:
IOException
-
getPayload
- Specified by:
getPayload
in classPostingsEnum
- Throws:
IOException
-
docID
public int docID()- Specified by:
docID
in classDocIdSetIterator
-
nextDoc
- Specified by:
nextDoc
in classDocIdSetIterator
- Throws:
IOException
-
advance
public int advance(int target) - Specified by:
advance
in classDocIdSetIterator
-
cost
public long cost()- Specified by:
cost
in classDocIdSetIterator
-