On Nov 30, 2004, at 7:10 AM, Karthik N S wrote:
On Search API the command [ package org.apache.lucene.document.Document ]

Will this 'public final String[] getValues(String name)' return me
all the docs with out looping thru ?

getValues(fieldName) returns a String[] of the values of the field. It's similar to getValue(fieldName). If you index a field multiple times:


        doc.add(Field.Keyword("keyword", "one"));
        doc.add(Field.Keyword("keyword", "two"));

getValue("keyword") will return "one", but getValues("keyword") will return a String[] {"one", "two"}

If you want to retrieve all documents, use IndexReader's various API methods.

        Erik


--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to