lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Christoph Goller <gol...@detego-software.de>
Subject Re: cvs commit: jakarta-lucene/src/java/org/apache/lucene/index MultiReader.java FilterIndexReader.java IndexReader.java SegmentReader.java
Date Mon, 19 Apr 2004 17:38:08 GMT
Doug Cutting wrote:
> Christoph,
> 
> Thanks again for all of your work.  This is a great patch.
> 
> One nit, however:
> 
> goller@apache.org wrote:
> 
>>   +  protected IndexReader(Directory directory, SegmentInfos 
>> segmentInfos, boolean closeDirectory) {
> 
> 
> The non-public SegmentInfos makes an appearance here in a public API. 
> Perhaps this constructor should be package-private.

Both constructors of IndexReader or at least the one with SegmentInfos should
be made package-private. Thats probably better than protected.

> 
> Or perhaps, since the SegmentInfos instance is only used once on line 
> 414, for version checking, we should instead add an abstract 
> getVersion() method implemented by subclasses.  Could that work?

DonĀ“t know exactly what you mean here. We already have the getCurrentVersion
method in IndexReader, but you probably mean something else.

Do you agree to the changes concerning the bahavior of undeleteAll and close?

Christoph



---------------------------------------------------------------------
To unsubscribe, e-mail: lucene-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: lucene-dev-help@jakarta.apache.org


Mime
View raw message