@Deprecated public final class SlowCompositeReaderWrapper extends LeafReader
MultiReader or DirectoryReader) to emulate a
LeafReader. This requires implementing the postings
APIs on-the-fly, using the static methods in MultiFields, MultiDocValues, by stepping through
the sub-readers to merge fields/terms, appending docs, etc.
NOTE: this class almost always results in a
performance hit. If this is important to your use case,
you'll get better performance by gathering the sub readers using
IndexReader.getContext() to get the
leaves and then operate per-LeafReader,
instead of using this class.
LeafReader.CoreClosedListenerIndexReader.ReaderClosedListeneraddCoreClosedListenerAsReaderClosedListener, docFreq, getContext, getDocCount, getSumDocFreq, getSumTotalTermFreq, postings, postings, removeCoreClosedListenerAsReaderClosedListener, terms, totalTermFreqaddReaderClosedListener, close, decRef, document, document, ensureOpen, equals, getRefCount, getTermVector, hasDeletions, hashCode, incRef, leaves, numDeletedDocs, registerParentReader, removeReaderClosedListener, tryIncRefpublic static LeafReader wrap(IndexReader reader) throws IOException
LeafReader from
an IndexReader of any kind. If the reader is already atomic,
it is returned unchanged, otherwise wrapped by this class.IOExceptionpublic void addCoreClosedListener(LeafReader.CoreClosedListener listener)
addCoreClosedListener in class LeafReaderpublic void removeCoreClosedListener(LeafReader.CoreClosedListener listener)
removeCoreClosedListener in class LeafReaderpublic Fields fields()
fields in class LeafReaderpublic NumericDocValues getNumericDocValues(String field) throws IOException
getNumericDocValues in class LeafReaderIOExceptionpublic Bits getDocsWithField(String field) throws IOException
getDocsWithField in class LeafReaderIOExceptionpublic BinaryDocValues getBinaryDocValues(String field) throws IOException
getBinaryDocValues in class LeafReaderIOExceptionpublic SortedNumericDocValues getSortedNumericDocValues(String field) throws IOException
getSortedNumericDocValues in class LeafReaderIOExceptionpublic SortedDocValues getSortedDocValues(String field) throws IOException
getSortedDocValues in class LeafReaderIOExceptionpublic SortedSetDocValues getSortedSetDocValues(String field) throws IOException
getSortedSetDocValues in class LeafReaderIOExceptionpublic NumericDocValues getNormValues(String field) throws IOException
getNormValues in class LeafReaderIOExceptionpublic Fields getTermVectors(int docID) throws IOException
getTermVectors in class IndexReaderIOExceptionpublic int numDocs()
numDocs in class IndexReaderpublic int maxDoc()
maxDoc in class IndexReaderpublic void document(int docID,
StoredFieldVisitor visitor)
throws IOException
document in class IndexReaderIOExceptionpublic Bits getLiveDocs()
getLiveDocs in class LeafReaderpublic PointValues getPointValues()
getPointValues in class LeafReaderpublic FieldInfos getFieldInfos()
getFieldInfos in class LeafReaderpublic Object getCoreCacheKey()
getCoreCacheKey in class IndexReaderpublic Object getCombinedCoreAndDeletesKey()
getCombinedCoreAndDeletesKey in class IndexReaderprotected void doClose()
throws IOException
doClose in class IndexReaderIOExceptionpublic void checkIntegrity()
throws IOException
checkIntegrity in class LeafReaderIOExceptionpublic Sort getIndexSort()
getIndexSort in class LeafReaderCopyright © 2000-2018 Apache Software Foundation. All Rights Reserved.