Hi I have few questions about implementation of inputstream in S3.
1)public synchronized long getPos() throws IOException {return (nextReadPos <
0) ? 0 : nextReadPos;}Why does it return nextReadPos not pos?In memeber
definition for pos/*** This is the public position; the one set in {@link
#seek(long)}* and returned in {@link #getPos()}.*/private long pos;
2)seekInStreamIn the last lines you have:// close the stream; if read the
object will be opened at the new poscloseStream("seekInStream()",
this.requestedStreamLen);pos = targetPos; Why you need this line? Shouldn`t pos
be updated with actual skipped value? As you did:
| if (skipped > 0) { |
|
| pos += skipped; |
Thanks