lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From vasu shah <vasusha...@yahoo.com>
Subject Parameterized IndexModifier
Date Tue, 17 Oct 2006 23:23:31 GMT

Hi,

The IndexModifier class always opens up an IndexWriter in the init 
method. If we need to update a document, it closes the IndexWriter and 
opens up IndexReader to delete the desired document. Then again it opens 
IndexWriter to add the document to the index.

Instead can't we pass one extra parameter to the constructor that 
determines whether the operation required is exclusively insert or 
delete/update. If it is just insert, we open the IndexWriter first. If it is 
delete/update, we open IndexReader first.

If we do this will there be any issues?

Thanks,
-Vasu

 		
---------------------------------
How low will we go? Check out Yahoo! Messenger’s low  PC-to-Phone call rates.
Mime
  • Unnamed multipart/alternative (inline, 8-Bit, 0 bytes)
View raw message