There really isn't a generic way... you have to search for the document. If you have a unique id field in your document, you can find the document id quickly via IndexReader.termDocs(term)
-Yonik Now hiring -- http://forms.cnet.com/slink?231706 On 11/9/05, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: > > If I have a Document object (doc), and I also have an IndexReader open, > how can I find out IndexReader's docid corresponding to (doc)? > > IndexReader has a map from docid -> Document, but I don't see the reverse. > > thanks in advance, > Todd --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]