public final class OwnCacheKeyMultiReader extends MultiReader
MultiReader that has its own cache key, occasionally useful for
testing purposes.IndexReader.CacheHelper, IndexReader.CacheKey, IndexReader.ClosedListener| Constructor and Description |
|---|
OwnCacheKeyMultiReader(IndexReader... subReaders)
Sole constructor.
|
| Modifier and Type | Method and Description |
|---|---|
IndexReader.CacheHelper |
getReaderCacheHelper()
Optional method: Return a
IndexReader.CacheHelper that can be used to cache
based on the content of this reader. |
doClosedocFreq, document, getDocCount, getSequentialSubReaders, getSumDocFreq, getSumTotalTermFreq, getTermVectors, maxDoc, numDocs, readerBase, readerIndex, totalTermFreqgetContext, toStringclose, decRef, document, document, ensureOpen, equals, getRefCount, getTermVector, hasDeletions, hashCode, incRef, leaves, numDeletedDocs, registerParentReader, tryIncRefpublic OwnCacheKeyMultiReader(IndexReader... subReaders) throws java.io.IOException
java.io.IOExceptionpublic IndexReader.CacheHelper getReaderCacheHelper()
IndexReaderIndexReader.CacheHelper that can be used to cache
based on the content of this reader. Two readers that have different data
or different sets of deleted documents will be considered different.
A return value of null indicates that this reader is not suited
for caching, which is typically the case for short-lived wrappers that
alter the content of the wrapped reader.
getReaderCacheHelper in class MultiReaderCopyright © 2000–2025 The Apache Software Foundation. All rights reserved.