Thank you for your quick answer.

I agree that create=true indicates that it's ok to overwrite. But when
create=false and the index does not exists, I get a FileNotFoundException.

I expected something like java.io.FileOutputStream 'append' flag :
false = overwrite
true = If the file exists, use it. If not, create an empty one

The choice of the constructor does not depend on "Does that file exist ?"  but
rather on "Do I overwrite a possibly existing file ?".


JCG



|--------+------------------------------->
|        |          David Spencer        |
|        |          <[EMAIL PROTECTED]>     |
|        |                               |
|        |          04.12.2001 16:19     |
|        |          Please respond to    |
|        |          "Lucene Users List"  |
|        |                               |
|--------+------------------------------->
  >-------------------------------------------------------------------------|
  |                                                                         |
  |      To:   Lucene Users List <[EMAIL PROTECTED]>           |
  |      cc:                                                                |
  |      Subject:   Re: existing or not existing                            |
  >-------------------------------------------------------------------------|





I think the 'create' flag really indicates whether it's ok
to *overwrite* the *possibly*existing* index.
Despite the tricky nuance it works great.





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

Reply via email to