As of Lucene2.1, IndexWriter grew a deleteDocuments method: http://lucene.apache.org/java/2_1_0/api/org/apache/lucene/index/IndexWriter.html http://lucene.apache.org/java/2_1_0/api/org/apache/lucene/index/IndexWriter.html#deleteDocuments(org.apache.lucene.index.Term)
This method used to be only available on IndexReader, while addDocument is on IndexWriter. This makes writing code that both adds & deletes documents much more natural. However, the deleteDocuments method doesn't appear to be in PyLucene: In [1]: from PyLucene import * In [2]: VERSION Out[2]: '2.1.0-2' In [3]: IndexWriter.deleteDocuments --------------------------------------------------------------------------- AttributeError: type object 'PyLucene.IndexWriter' has no attribute 'deleteDocuments' I suspect this wrapping for this method was just overlooked: http://svn.osafoundation.org/pylucene/trunk/CHANGES I only noticed the Java version when browsing the Lucene Changelog: http://svn.apache.org/repos/asf/lucene/java/tags/lucene_2_1_0/CHANGES.txt Originating Ticket in Lucene's JIRA (warning: it's long & boring): http://issues.apache.org/jira/browse/LUCENE-565 -- Peter Fein || 773-575-0694 || [EMAIL PROTECTED] http://www.pobox.com/~pfein/ || PGP: 0xCCF6AE6B irc: [EMAIL PROTECTED] || jabber: [EMAIL PROTECTED] _______________________________________________ pylucene-dev mailing list [email protected] http://lists.osafoundation.org/mailman/listinfo/pylucene-dev
