public abstract static class ObservableInputStream.Observer
extends java.lang.Object
| Constructor and Description |
|---|
Observer() |
| Modifier and Type | Method and Description |
|---|---|
(package private) void |
closed()
Called to indicate, that the
ObservableInputStream has been closed. |
(package private) void |
data(byte[] pBuffer,
int pOffset,
int pLength)
Called to indicate, that
InputStream.read(byte[]), or
InputStream.read(byte[], int, int) have been called, and are about to
invoke data. |
(package private) void |
data(int pByte)
Called to indicate, that
InputStream.read() has been invoked
on the ObservableInputStream, and will return a value. |
(package private) void |
error(java.io.IOException pException)
Called to indicate, that an error occurred on the underlying stream.
|
(package private) void |
finished()
Called to indicate, that EOF has been seen on the underlying stream.
|
void data(int pByte) throws java.io.IOException
InputStream.read() has been invoked
on the ObservableInputStream, and will return a value.pByte - The value, which is being returned. This will never be -1 (EOF),
because, in that case, finished() will be invoked instead.java.io.IOException - if an i/o-error occursvoid data(byte[] pBuffer,
int pOffset,
int pLength)
throws java.io.IOException
InputStream.read(byte[]), or
InputStream.read(byte[], int, int) have been called, and are about to
invoke data.pBuffer - The byte array, which has been passed to the read call, and where
data has been stored.pOffset - The offset within the byte array, where data has been stored.pLength - The number of bytes, which have been stored in the byte array.java.io.IOException - if an i/o-error occursvoid finished()
throws java.io.IOException
java.io.IOException - if an i/o-error occursvoid closed()
throws java.io.IOException
ObservableInputStream has been closed.java.io.IOException - if an i/o-error occursvoid error(java.io.IOException pException)
throws java.io.IOException
java.io.IOException - if an i/o-error occurs