lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jean-christian.ga...@prasahewitt.ch
Subject Re: existing or not existing
Date Tue, 04 Dec 2001 16:01:10 GMT


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        |
|        |          <dave@tropo.com>     |
|        |                               |
|        |          04.12.2001 16:19     |
|        |          Please respond to    |
|        |          "Lucene Users List"  |
|        |                               |
|--------+------------------------------->
  >-------------------------------------------------------------------------|
  |                                                                         |
  |      To:   Lucene Users List <lucene-user@jakarta.apache.org>           |
  |      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:lucene-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:lucene-user-help@jakarta.apache.org>


Mime
View raw message