Uses of Class
org.apache.lucene.index.CodecReader
Packages that use CodecReader
Package
Description
Code to maintain and access indices.
Misc index tools and index support.
-
Uses of CodecReader in org.apache.lucene.index
Subclasses of CodecReader in org.apache.lucene.indexModifier and TypeClassDescriptionclass
AFilterCodecReader
contains another CodecReader, which it uses as its basic source of data, possibly transforming the data along the way or providing additional functionality.final class
IndexReader implementation over a single segment.(package private) final class
A mergedCodecReader
view of multipleCodecReader
.(package private) static final class
final class
AnCodecReader
which supports sorting documents by a givenSort
.Fields in org.apache.lucene.index declared as CodecReaderModifier and TypeFieldDescription(package private) final CodecReader
MergePolicy.MergeReader.codecReader
private final CodecReader[]
SlowCompositeCodecReaderWrapper.codecReaders
private final CodecReader[]
SlowCompositeCodecReaderWrapper.SlowCompositeDocValuesProducerWrapper.codecReaders
private final CodecReader[]
SlowCompositeCodecReaderWrapper.SlowCompositeKnnVectorsReaderWrapper.codecReaders
private final CodecReader[]
SlowCompositeCodecReaderWrapper.SlowCompositeNormsProducer.codecReaders
private final CodecReader[]
SlowCompositeCodecReaderWrapper.SlowCompositePointsReaderWrapper.codecReaders
protected final CodecReader
FilterCodecReader.in
The underlying CodecReader instance.Methods in org.apache.lucene.index that return CodecReaderModifier and TypeMethodDescription(package private) static CodecReader
SoftDeletesRetentionMergePolicy.applyRetentionQuery
(String softDeleteField, Query retentionQuery, CodecReader reader) FilterCodecReader.getDelegate()
Returns the wrappedCodecReader
.private CodecReader
ReadersAndUpdates.getLatestReader()
static CodecReader
FilterCodecReader.unwrap
(CodecReader reader) Get the wrapped instance byreader
as long as this reader is an instance ofFilterCodecReader
.static CodecReader
SlowCodecReaderWrapper.wrap
(LeafReader reader) Returns aCodecReader
view of reader.(package private) static CodecReader
SlowCompositeCodecReaderWrapper.wrap
(List<CodecReader> readers) static CodecReader
SortingCodecReader.wrap
(CodecReader reader, Sorter.DocMap docMap, Sort sort) Expert: same asSortingCodecReader.wrap(org.apache.lucene.index.CodecReader, Sort)
but operates directly on aSorter.DocMap
.static CodecReader
SortingCodecReader.wrap
(CodecReader reader, Sort sort) Return a sorted view ofreader
according to the order defined bysort
.MergePolicy.OneMerge.wrapForMerge
(CodecReader reader) Wrap a reader prior to merging in order to add/remove fields or documents.Methods in org.apache.lucene.index with parameters of type CodecReaderModifier and TypeMethodDescriptionlong
IndexWriter.addIndexes
(CodecReader... readers) Merges the provided indexes into this index.(package private) static CodecReader
SoftDeletesRetentionMergePolicy.applyRetentionQuery
(String softDeleteField, Query retentionQuery, CodecReader reader) private boolean
IndexWriter.assertSoftDeletesCount
(CodecReader reader, int expectedCount) private static void
CheckIndex.checkByteVectorValues
(ByteVectorValues values, FieldInfo fieldInfo, CheckIndex.Status.VectorValuesStatus status, CodecReader codecReader) private static void
CheckIndex.checkFloatVectorValues
(FloatVectorValues values, FieldInfo fieldInfo, CheckIndex.Status.VectorValuesStatus status, CodecReader codecReader) private void
IndexWriter.countSoftDeletes
(CodecReader reader, Bits wrappedLiveDocs, Bits hardLiveDocs, Counter softDeleteCounter, Counter hardDeleteCounter) FilterMergePolicy.findMerges
(CodecReader... readers) MergePolicy.findMerges
(CodecReader... readers) Define the set of merge operations to perform on provided codec readers inIndexWriter.addIndexes(CodecReader...)
.NoMergePolicy.findMerges
(CodecReader... readers) private static Scorer
SoftDeletesRetentionMergePolicy.getScorer
(Query query, CodecReader reader) (package private) final boolean
PendingDeletes.needsRefresh
(CodecReader reader) Returns true if the given reader needs to be refreshed in order to see the latest deletes(package private) void
PendingDeletes.onNewReader
(CodecReader reader, SegmentCommitInfo info) Called once a new reader is opened for this segment ie.(package private) void
PendingSoftDeletes.onNewReader
(CodecReader reader, SegmentCommitInfo info) MergePolicy.OneMerge.reorder
(CodecReader reader, Directory dir, Executor executor) Extend this method if you wish to renumber doc IDs.CheckIndex.testDocValues
(CodecReader reader, PrintStream infoStream, boolean failFast) Test docvalues.CheckIndex.testFieldInfos
(CodecReader reader, PrintStream infoStream, boolean failFast) Test field infos.CheckIndex.testFieldNorms
(CodecReader reader, PrintStream infoStream, boolean failFast) Test field norms.CheckIndex.testLiveDocs
(CodecReader reader, PrintStream infoStream, boolean failFast) Test live docs.CheckIndex.testPoints
(CodecReader reader, PrintStream infoStream, boolean failFast) Test the points index.CheckIndex.testPostings
(CodecReader reader, PrintStream infoStream) Test the term index.CheckIndex.testPostings
(CodecReader reader, PrintStream infoStream, boolean verbose, boolean doSlowChecks, boolean failFast) Test the term index.CheckIndex.testSort
(CodecReader reader, Sort sort, PrintStream infoStream, boolean failFast) Tests index sort order.CheckIndex.testStoredFields
(CodecReader reader, PrintStream infoStream, boolean failFast) Test stored fields.CheckIndex.testTermVectors
(CodecReader reader, PrintStream infoStream) Test term vectors.CheckIndex.testTermVectors
(CodecReader reader, PrintStream infoStream, boolean verbose, boolean doSlowChecks, boolean failFast) Test term vectors.CheckIndex.testVectors
(CodecReader reader, PrintStream infoStream, boolean failFast) Test the vectors index.static CodecReader
FilterCodecReader.unwrap
(CodecReader reader) Get the wrapped instance byreader
as long as this reader is an instance ofFilterCodecReader
.private void
IndexWriter.validateMergeReader
(CodecReader leaf) private static boolean
CheckIndex.vectorsReaderSupportsSearch
(CodecReader codecReader, String fieldName) (package private) boolean
PendingDeletes.verifyDocCounts
(CodecReader reader) static CodecReader
SortingCodecReader.wrap
(CodecReader reader, Sorter.DocMap docMap, Sort sort) Expert: same asSortingCodecReader.wrap(org.apache.lucene.index.CodecReader, Sort)
but operates directly on aSorter.DocMap
.static CodecReader
SortingCodecReader.wrap
(CodecReader reader, Sort sort) Return a sorted view ofreader
according to the order defined bysort
.MergePolicy.OneMerge.wrapForMerge
(CodecReader reader) Wrap a reader prior to merging in order to add/remove fields or documents.(package private) static FilterCodecReader
FilterCodecReader.wrapLiveDocs
(CodecReader reader, Bits liveDocs, int numDocs) Returns a filtered codec reader with the given live docs and numDocs.Method parameters in org.apache.lucene.index with type arguments of type CodecReaderModifier and TypeMethodDescriptionprivate MergeState.DocMap[]
MergeState.buildDeletionDocMaps
(List<CodecReader> readers) private MergeState.DocMap[]
MergeState.buildDocMaps
(List<CodecReader> readers, Sort indexSort) private void
PendingSoftDeletes.ensureInitialized
(IOSupplier<CodecReader> readerIOSupplier) (package private) boolean
PendingDeletes.isFullyDeleted
(IOSupplier<CodecReader> readerIOSupplier) Returnstrue
iff the segment represented by thisPendingDeletes
is fully deleted(package private) boolean
PendingSoftDeletes.isFullyDeleted
(IOSupplier<CodecReader> readerIOSupplier) boolean
FilterMergePolicy.keepFullyDeletedSegment
(IOSupplier<CodecReader> readerIOSupplier) boolean
MergePolicy.keepFullyDeletedSegment
(IOSupplier<CodecReader> readerIOSupplier) Returns true if the segment represented by the given CodecReader should be keep even if it's fully deleted.boolean
NoMergePolicy.keepFullyDeletedSegment
(IOSupplier<CodecReader> readerIOSupplier) boolean
SoftDeletesRetentionMergePolicy.keepFullyDeletedSegment
(IOSupplier<CodecReader> readerIOSupplier) int
FilterMergePolicy.numDeletesToMerge
(SegmentCommitInfo info, int delCount, IOSupplier<CodecReader> readerSupplier) int
MergePolicy.numDeletesToMerge
(SegmentCommitInfo info, int delCount, IOSupplier<CodecReader> readerSupplier) Returns the number of deletes that a merge would claim on the given segment.int
NoMergePolicy.numDeletesToMerge
(SegmentCommitInfo info, int delCount, IOSupplier<CodecReader> readerSupplier) (package private) int
PendingDeletes.numDeletesToMerge
(MergePolicy policy, IOSupplier<CodecReader> readerIOSupplier) (package private) int
PendingSoftDeletes.numDeletesToMerge
(MergePolicy policy, IOSupplier<CodecReader> readerIOSupplier) int
SoftDeletesRetentionMergePolicy.numDeletesToMerge
(SegmentCommitInfo info, int delCount, IOSupplier<CodecReader> readerSupplier) (package private) static MergeState.DocMap[]
MultiSorter.sort
(Sort sort, List<CodecReader> readers) Does a merge sort of the leaves of the incoming reader, returningMergeState.DocMap
to map each leaf's documents into the merged segment.private static void
MergeState.verifyIndexSort
(List<CodecReader> readers, SegmentInfo segmentInfo) (package private) static CodecReader
SlowCompositeCodecReaderWrapper.wrap
(List<CodecReader> readers) Constructors in org.apache.lucene.index with parameters of type CodecReaderModifierConstructorDescriptionCreates a new FilterCodecReader.(package private)
MergeReader
(CodecReader reader, Bits hardLiveDocs) OneMerge
(CodecReader... codecReaders) Create a OneMerge directly from CodecReaders.(package private)
SlowCompositeDocValuesProducerWrapper
(CodecReader[] codecReaders, int[] docStarts) (package private)
SlowCompositeKnnVectorsReaderWrapper
(CodecReader[] codecReaders, int[] docStarts) (package private)
SlowCompositeNormsProducer
(CodecReader[] codecReaders) (package private)
SlowCompositePointsReaderWrapper
(CodecReader[] codecReaders, int[] docStarts) private
SoftDeletesFilterCodecReader
(CodecReader reader, FixedBitSet bits, int numDocs) private
SortingCodecReader
(CodecReader in, Sorter.DocMap docMap, LeafMetaData metaData) Constructor parameters in org.apache.lucene.index with type arguments of type CodecReaderModifierConstructorDescription(package private)
MergeState
(List<CodecReader> readers, SegmentInfo segmentInfo, InfoStream infoStream, Executor intraMergeTaskExecutor) Sole constructor.(package private)
SegmentMerger
(List<CodecReader> readers, SegmentInfo segmentInfo, InfoStream infoStream, Directory dir, FieldInfos.FieldNumbers fieldNumbers, IOContext context, Executor intraMergeTaskExecutor) private
SlowCompositeCodecReaderWrapper
(List<CodecReader> codecReaders) -
Uses of CodecReader in org.apache.lucene.misc.index
Subclasses of CodecReader in org.apache.lucene.misc.indexModifier and TypeClassDescriptionprivate static class
private static final class
private static class
Methods in org.apache.lucene.misc.index that return CodecReaderModifier and TypeMethodDescriptionBPIndexReorderer.reorder
(CodecReader reader, Directory tempDir, Executor executor) Reorder the givenCodecReader
into a reader that tries to minimize the log gap between consecutive documents in postings, which usually helps improve space efficiency and query evaluation efficiency.Methods in org.apache.lucene.misc.index with parameters of type CodecReaderModifier and TypeMethodDescriptionBPIndexReorderer.computeDocMap
(CodecReader reader, Directory tempDir, Executor executor) Expert: Compute theSorter.DocMap
that holds the new doc ID numbering.private int[]
BPIndexReorderer.computePermutation
(CodecReader reader, Set<String> fields, Directory dir, TaskExecutor executor) Compute a permutation of the doc ID space that reduces log gaps between consecutive postings.BPReorderingMergePolicy.findMerges
(CodecReader... readers) BinaryDocValueSelector.getFilteredLiveDocs
(CodecReader reader) IndexRearranger.DocumentSelector.getFilteredLiveDocs
(CodecReader reader) BPIndexReorderer.reorder
(CodecReader reader, Directory tempDir, Executor executor) Reorder the givenCodecReader
into a reader that tries to minimize the log gap between consecutive documents in postings, which usually helps improve space efficiency and query evaluation efficiency.private int
BPIndexReorderer.writePostings
(CodecReader reader, Set<String> fields, Directory tempDir, DataOutput postingsOut, int parallelism) Constructors in org.apache.lucene.misc.index with parameters of type CodecReader