On May 31, 2005, at 4:06 AM, Paul Libbrecht wrote:
Le 30 mai 05, à 22:13, Doug Hughes a écrit :
Ok, so more than one keyword can be stored in a keyword field.
Interesting!
Yes, yes, yes!! You can do:
doc.add("link","xx");
doc.add("link","yy");
Well, that's not quite correct API, but your point is accurate :)
and matches will match any of them!
I found this in the book and not in the javadoc and I'd recommed
adding it in the javadoc of the add method, it's a non-obvious
goodness which suits all forms of scalability!
Fields are made up of terms. A Field.Keyword makes a single term for
a field. Adding multiple fields with the same name works even if its
not Field.Keyword - it simply adds the term(s) to the field.
Good point about documentation - it would be worth noting this
explicitly.
Erik
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]