System.out.println("Indexing " + f.getAbsolutePath());
Document doc = new Document();
doc.add(new Field("contents",loadContents
(doc),Field.Store.NO,Field.Index.TOKENIZED));
doc.add(new Field("filename",
f.getAbsolutePath(),Field.Stor
My apologies, the IndexReader code I included was a commented out trial.
Here is the active version. Sorry for the error:
IndexReader ir = IndexReader.open(indexDir);
System.out.println(">>>" + ir.numDocs());
int deleted = ir.deleteDocuments(new Ter
Hello,
I'm brand new to this, so hopefully you can help me. I'm
attempting to use the IndexReader object in lucene v2 to delete and readd
documents. I very easily set up an index and my documents are added. Now
I'm trying to update the same index by deleting the document before
readdin