Prev Class | Next Class | Frames | No Frames |
Summary: Nested | Field | Method | Constr | Detail: Nested | Field | Method | Constr |
java.lang.Object
org.apache.lucene.index.IndexReader
org.apache.lucene.index.MultiReader
public class MultiReader
extends IndexReader
Constructor Summary | |
|
Method Summary | |
protected void |
|
protected void |
|
protected void |
|
protected void |
|
protected void | |
int | |
Document |
|
Collection | |
Collection |
|
Collection |
|
TermFreqVector |
|
TermFreqVector[] |
|
boolean | |
boolean |
|
int |
|
byte[] |
|
void |
|
int |
|
TermDocs |
|
TermPositions | |
TermEnum |
|
TermEnum |
Methods inherited from class org.apache.lucene.index.IndexReader | |
close , commit , delete , delete , directory , doClose , doCommit , doDelete , doSetNorm , doUndeleteAll , docFreq , document , finalize , getCurrentVersion , getCurrentVersion , getCurrentVersion , getFieldNames , getFieldNames , getIndexedFieldNames , getTermFreqVector , getTermFreqVectors , hasDeletions , indexExists , indexExists , indexExists , isDeleted , isLocked , isLocked , lastModified , lastModified , lastModified , maxDoc , norms , norms , numDocs , open , open , open , setNorm , setNorm , termDocs , termDocs , termPositions , termPositions , terms , terms , undeleteAll , unlock |
public MultiReader(IndexReader[] subReaders) throws IOException
Construct a MultiReader aggregating the named set of (sub)readers. Directory locking for delete, undeleteAll, and setNorm operations is left to the subreaders. Note that all subreaders are closed if this Multireader is closed.
- Parameters:
subReaders
- set of (sub)readers
protected void doDelete(int n) throws IOException
- Overrides:
- doDelete in interface IndexReader
protected void doSetNorm(int n, String field, byte value) throws IOException
- Overrides:
- doSetNorm in interface IndexReader
protected void doUndeleteAll() throws IOException
- Overrides:
- doUndeleteAll in interface IndexReader
public Document document(int n) throws IOException
- Overrides:
- document in interface IndexReader
public Collection getFieldNames() throws IOException
- Overrides:
- getFieldNames in interface IndexReader
- See Also:
IndexReader.getFieldNames()
public Collection getFieldNames(boolean indexed) throws IOException
- Overrides:
- getFieldNames in interface IndexReader
- See Also:
IndexReader.getFieldNames(boolean)
public Collection getIndexedFieldNames(boolean storedTermVector)
- Overrides:
- getIndexedFieldNames in interface IndexReader
public TermFreqVector getTermFreqVector(int n, String field) throws IOException
- Overrides:
- getTermFreqVector in interface IndexReader
public TermFreqVector[] getTermFreqVectors(int n) throws IOException
Return an array of term frequency vectors for the specified document. The array contains a vector for each vectorized field in the document. Each vector vector contains term numbers and frequencies for all terms in a given vectorized field. If no such fields existed, the method returns null.
- Overrides:
- getTermFreqVectors in interface IndexReader
public void norms(String field, byte[] result, int offset) throws IOException
- Overrides:
- norms in interface IndexReader
public TermPositions termPositions() throws IOException
- Overrides:
- termPositions in interface IndexReader