Methods Summary |
---|
public int | available()Returns the number of bytes that are available before this stream will
block.
return in.available();
|
public void | close()Closes this stream. This implementation closes the filtered stream.
in.close();
|
public synchronized void | mark(int readlimit)Sets a mark position in this stream. The parameter {@code readlimit}
indicates how many bytes can be read before the mark is invalidated.
Sending {@code reset()} will reposition this stream back to the marked
position, provided that {@code readlimit} has not been surpassed.
This implementation sets a mark in the filtered stream.
in.mark(readlimit);
|
public boolean | markSupported()Indicates whether this stream supports {@code mark()} and {@code reset()}.
This implementation returns whether or not the filtered stream supports
marking.
return in.markSupported();
|
public int | read()Reads a single byte from the filtered stream and returns it as an integer
in the range from 0 to 255. Returns -1 if the end of this stream has been
reached.
return in.read();
|
public int | read(byte[] buffer)Reads bytes from this stream and stores them in the byte array
{@code buffer}. Returns the number of bytes actually read or -1 if no
bytes were read and the end of this stream was encountered. This
implementation reads bytes from the filtered stream.
return read(buffer, 0, buffer.length);
|
public int | read(byte[] buffer, int offset, int count)Reads at most {@code count} bytes from this stream and stores them in the
byte array {@code buffer} starting at {@code offset}. Returns the number
of bytes actually read or -1 if no bytes have been read and the end of
this stream has been reached. This implementation reads bytes from the
filtered stream.
return in.read(buffer, offset, count);
|
public synchronized void | reset()Resets this stream to the last marked location. This implementation
resets the target stream.
in.reset();
|
public long | skip(long count)Skips {@code count} number of bytes in this stream. Subsequent
{@code read()}'s will not return these bytes unless {@code reset()} is
used. This implementation skips {@code count} number of bytes in the
filtered stream.
return in.skip(count);
|