lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Christoph Goller <>
Subject Re: CompoundFileReader
Date Thu, 20 Nov 2003 19:02:32 GMT

Otis Gospodnetic schrieb:
> Hello Christoph,
> I don't know enough to judge all changes you made with confidence, and
> don't have the code on this machine to apply the patch and look at it
> properly.  However, it looks like seekInternal(long) should now be left
> with only the conditionals that can cause IOException, and nothing
> else.  Why do we need to keep the body of the method then?

I discussed that already with Dmitry and he was not very passionate
regarding these conditionals. Finally I kept them since they were required
by Dmitry's test. But throwing an exception on seek is
not a behavior implemented by the other subclasses of InputStream.
I decided to remove the conditionals and slightly changed the unit test.

If more index checks are desirable, I would put them into InputStream.
Despite that I added a "read past EOF" check to CSInputStream.readInternal
to guarantee the same behavior as FSInputStream.

> I also see getFilePointer() call, but can't tell where that method is. 
> I'll assume it's from the parent InputStream.


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message