public class LinearBufferedInputStream
extends java.io.FilterInputStream
This implementation is not thread-safe.
Constructor and Description |
---|
LinearBufferedInputStream(java.io.InputStream is,
int bufferSize)
Creates a new linear buffered input stream reading from the specified stream.
|
Modifier and Type | Method and Description |
---|---|
int |
available() |
void |
close() |
void |
mark(int readLimit) |
boolean |
markSupported() |
int |
read() |
int |
read(byte[] buffer,
int byteOffset,
int byteCount) |
void |
reset() |
public LinearBufferedInputStream(java.io.InputStream is, int bufferSize)
is
- the input stream, must be non-nullbufferSize
- the buffer size (in bytes), must be positivejava.lang.IllegalArgumentException
- in case some of the arguments are not validpublic int read() throws java.io.IOException
read
in class java.io.FilterInputStream
java.io.IOException
public int read(byte[] buffer, int byteOffset, int byteCount) throws java.io.IOException
read
in class java.io.FilterInputStream
java.io.IOException
public int available() throws java.io.IOException
available
in class java.io.FilterInputStream
java.io.IOException
public void close() throws java.io.IOException
close
in interface java.io.Closeable
close
in interface java.lang.AutoCloseable
close
in class java.io.FilterInputStream
java.io.IOException
public void mark(int readLimit)
mark
in class java.io.FilterInputStream
public void reset() throws java.io.IOException
reset
in class java.io.FilterInputStream
java.io.IOException
public boolean markSupported()
markSupported
in class java.io.FilterInputStream