You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-user@lucene.apache.org by Itamar Syn-Hershko <it...@divrei-tora.com> on 2008/06/09 22:52:52 UTC
Options of Field constructor accepting Reader
Hi all,
I was wondering why only the Field constructor which accepts a String offers
Store and Index options? I understand there might be no logic in offering
them for the TokenStream constructor, but what's wrong in Storing an input
from a Reader, that 2.3.2 does not allow it?
Itamar.
Re: Options of Field constructor accepting Reader
Posted by Chris Hostetter <ho...@fucit.org>.
: I was wondering why only the Field constructor which accepts a String offers
: Store and Index options? I understand there might be no logic in offering
: them for the TokenStream constructor, but what's wrong in Storing an input
: from a Reader, that 2.3.2 does not allow it?
if you want to store all of the text associated with a Reader, then
"something" needs to slurp all of that text into a String -- the Lucene
API makes you be explicit about doing that (via the String constructor)
-Hoss
---------------------------------------------------------------------
To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
For additional commands, e-mail: java-user-help@lucene.apache.org