Package org.apache.lucene.tests.index
Class MismatchedLeafReader
- java.lang.Object
-
- org.apache.lucene.index.IndexReader
-
- org.apache.lucene.index.LeafReader
-
- org.apache.lucene.index.FilterLeafReader
-
- org.apache.lucene.tests.index.MismatchedLeafReader
-
- All Implemented Interfaces:
Closeable
,AutoCloseable
public class MismatchedLeafReader extends FilterLeafReader
Shuffles field numbers around to try to trip bugs where field numbers are assumed to always be consistent across segments.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.apache.lucene.index.FilterLeafReader
FilterLeafReader.FilterFields, FilterLeafReader.FilterPostingsEnum, FilterLeafReader.FilterTerms, FilterLeafReader.FilterTermsEnum
-
Nested classes/interfaces inherited from class org.apache.lucene.index.IndexReader
IndexReader.CacheHelper, IndexReader.CacheKey, IndexReader.ClosedListener
-
-
Field Summary
-
Fields inherited from class org.apache.lucene.index.FilterLeafReader
in
-
-
Constructor Summary
Constructors Constructor Description MismatchedLeafReader(LeafReader in, Random random)
Creates a new reader which will renumber fields inin
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
document(int docID, StoredFieldVisitor visitor)
IndexReader.CacheHelper
getCoreCacheHelper()
FieldInfos
getFieldInfos()
IndexReader.CacheHelper
getReaderCacheHelper()
void
searchNearestVectors(String field, byte[] target, KnnCollector knnCollector, Bits acceptDocs)
void
searchNearestVectors(String field, float[] target, KnnCollector knnCollector, Bits acceptDocs)
StoredFields
storedFields()
-
Methods inherited from class org.apache.lucene.index.FilterLeafReader
checkIntegrity, doClose, getBinaryDocValues, getByteVectorValues, getDelegate, getFloatVectorValues, getLiveDocs, getMetaData, getNormValues, getNumericDocValues, getPointValues, getSortedDocValues, getSortedNumericDocValues, getSortedSetDocValues, getTermVectors, maxDoc, numDocs, terms, termVectors, toString, unwrap
-
Methods inherited from class org.apache.lucene.index.LeafReader
docFreq, getContext, getDocCount, getSumDocFreq, getSumTotalTermFreq, postings, postings, searchNearestVectors, searchNearestVectors, totalTermFreq
-
Methods inherited from class org.apache.lucene.index.IndexReader
close, decRef, document, document, ensureOpen, equals, getRefCount, getTermVector, hasDeletions, hashCode, incRef, leaves, notifyReaderClosedListeners, numDeletedDocs, registerParentReader, tryIncRef
-
-
-
-
Constructor Detail
-
MismatchedLeafReader
public MismatchedLeafReader(LeafReader in, Random random)
Creates a new reader which will renumber fields inin
-
-
Method Detail
-
getFieldInfos
public FieldInfos getFieldInfos()
- Overrides:
getFieldInfos
in classFilterLeafReader
-
document
public void document(int docID, StoredFieldVisitor visitor) throws IOException
- Overrides:
document
in classFilterLeafReader
- Throws:
IOException
-
storedFields
public StoredFields storedFields() throws IOException
- Overrides:
storedFields
in classFilterLeafReader
- Throws:
IOException
-
getCoreCacheHelper
public IndexReader.CacheHelper getCoreCacheHelper()
- Specified by:
getCoreCacheHelper
in classLeafReader
-
getReaderCacheHelper
public IndexReader.CacheHelper getReaderCacheHelper()
- Specified by:
getReaderCacheHelper
in classIndexReader
-
searchNearestVectors
public void searchNearestVectors(String field, float[] target, KnnCollector knnCollector, Bits acceptDocs) throws IOException
- Overrides:
searchNearestVectors
in classFilterLeafReader
- Throws:
IOException
-
searchNearestVectors
public void searchNearestVectors(String field, byte[] target, KnnCollector knnCollector, Bits acceptDocs) throws IOException
- Overrides:
searchNearestVectors
in classFilterLeafReader
- Throws:
IOException
-
-