org.apache.jackrabbit.core.query.lucene
Class SearchIndex.CombinedIndexReader

java.lang.Object
  extended by org.apache.lucene.index.IndexReader
      extended by org.apache.lucene.index.MultiReader
          extended by org.apache.jackrabbit.core.query.lucene.SearchIndex.CombinedIndexReader
All Implemented Interfaces:
HierarchyResolver, MultiIndexReader
Enclosing class:
SearchIndex

protected static final class SearchIndex.CombinedIndexReader
extends org.apache.lucene.index.MultiReader
implements HierarchyResolver, MultiIndexReader

Combines multiple CachingMultiReader into a MultiReader with HierarchyResolver support.


Nested Class Summary
 
Nested classes/interfaces inherited from class org.apache.lucene.index.IndexReader
org.apache.lucene.index.IndexReader.FieldOption
 
Constructor Summary
SearchIndex.CombinedIndexReader(CachingMultiReader[] indexReaders)
           
 
Method Summary
 boolean equals(Object obj)
           
 org.apache.lucene.index.IndexReader[] getIndexReaders()
          
 int getParent(int n)
          Returns the document number of the parent of n or -1 if n does not have a parent (n is the root node).
 int hashCode()
           
 
Methods inherited from class org.apache.lucene.index.MultiReader
docFreq, doClose, doCommit, document, doDelete, doSetNorm, doUndeleteAll, getFieldNames, getTermFreqVector, getTermFreqVectors, hasDeletions, hasNorms, isDeleted, maxDoc, norms, norms, numDocs, termDocs, termPositions, terms, terms
 
Methods inherited from class org.apache.lucene.index.IndexReader
close, commit, deleteDocument, deleteDocuments, directory, finalize, getCurrentVersion, getCurrentVersion, getCurrentVersion, getVersion, indexExists, indexExists, indexExists, isCurrent, isLocked, isLocked, lastModified, lastModified, lastModified, main, open, open, open, setNorm, setNorm, termDocs, termPositions, undeleteAll, unlock
 
Methods inherited from class java.lang.Object
clone, getClass, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SearchIndex.CombinedIndexReader

public SearchIndex.CombinedIndexReader(CachingMultiReader[] indexReaders)
                                throws IOException
Throws:
IOException
Method Detail

getParent

public int getParent(int n)
              throws IOException
Description copied from interface: HierarchyResolver
Returns the document number of the parent of n or -1 if n does not have a parent (n is the root node).

Specified by:
getParent in interface HierarchyResolver
Parameters:
n - the document number.
Returns:
the document number of n's parent.
Throws:
IOException - if an error occurs while reading from the index.

getIndexReaders

public org.apache.lucene.index.IndexReader[] getIndexReaders()

Specified by:
getIndexReaders in interface MultiIndexReader
Returns:
the IndexReaders that are contained in this MultiIndexReader.

equals

public boolean equals(Object obj)
Overrides:
equals in class Object

hashCode

public int hashCode()
Overrides:
hashCode in class Object


Copyright © 2004-2007 The Apache Software Foundation. All Rights Reserved.