edu.mayo.informatics.indexer.lucene
Class LuceneIndexReader

java.lang.Object
  extended by edu.mayo.informatics.indexer.lucene.LuceneIndexReader

public class LuceneIndexReader
extends java.lang.Object

The wrapper for the Index Reader.

Author:
Dan Armbrust

Constructor Summary
LuceneIndexReader(java.io.File location)
           
LuceneIndexReader(java.io.File location, boolean useInMemoryIndex)
           
 
Method Summary
 void close()
           
 int delete(java.lang.String uniqueDocumentId)
           
 int delete(java.lang.String field, java.lang.String uniqueDocumentId)
           
 org.apache.lucene.document.Document document(int docIndex)
           
 org.apache.lucene.index.IndexReader getBaseIndexReader()
           
 boolean isInMemory()
           
 int maxDoc()
           
 void reopen()
           
 java.util.Collection searchableFields()
           
 boolean upToDate()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

LuceneIndexReader

public LuceneIndexReader(java.io.File location)
                  throws InternalIndexerErrorException
Throws:
InternalIndexerErrorException

LuceneIndexReader

public LuceneIndexReader(java.io.File location,
                         boolean useInMemoryIndex)
                  throws InternalIndexerErrorException
Throws:
InternalIndexerErrorException
Method Detail

isInMemory

public boolean isInMemory()

delete

public int delete(java.lang.String uniqueDocumentId)
           throws InternalIndexerErrorException
Throws:
InternalIndexerErrorException

getBaseIndexReader

public org.apache.lucene.index.IndexReader getBaseIndexReader()

delete

public int delete(java.lang.String field,
                  java.lang.String uniqueDocumentId)
           throws InternalIndexerErrorException
Throws:
InternalIndexerErrorException

close

public void close()
           throws InternalIndexerErrorException
Throws:
InternalIndexerErrorException

searchableFields

public java.util.Collection searchableFields()

maxDoc

public int maxDoc()

document

public org.apache.lucene.document.Document document(int docIndex)
                                             throws InternalIndexerErrorException
Throws:
InternalIndexerErrorException

upToDate

public boolean upToDate()

reopen

public void reopen()
            throws InternalIndexerErrorException
Throws:
InternalIndexerErrorException

Copyright: (c) 2004-2006 Mayo Foundation for Medical Education and Research (MFMER). All rights reserved. MAYO, MAYO CLINIC, and the triple-shield Mayo logo are trademarks and service marks of MFMER.