Class SlowMultiReaderWrapper

  • All Implemented Interfaces:
    Closeable, AutoCloseable, Cloneable

    public class SlowMultiReaderWrapper
    extends MultiReader
    Acts like Lucene 4.x's SlowMultiReaderWrapper for testing of top-level MultiTermEnum, MultiTermDocs, ...
    • Constructor Detail

      • SlowMultiReaderWrapper

        public SlowMultiReaderWrapper​(IndexReader reader)
    • Method Detail

      • getSequentialSubReaders

        public IndexReader[] getSequentialSubReaders()
        Description copied from class: IndexReader
        Expert: returns the sequential sub readers that this reader is logically composed of. For example, IndexSearcher uses this API to drive searching by one sub reader at a time. If this reader is not composed of sequential child readers, it should return null. If this method returns an empty array, that means this reader is a null reader (for example a MultiReader that has no sub readers).

        NOTE: You should not try using sub-readers returned by this method to make any changes (setNorm, deleteDocument, etc.). While this might succeed for one composite reader (like MultiReader), it will most likely lead to index corruption for other readers (like DirectoryReader obtained through IndexReader.open(org.apache.lucene.store.Directory). Use the parent reader directly.

        Overrides:
        getSequentialSubReaders in class MultiReader