@Beta public class TestableByteArrayInputStream extends ByteArrayInputStream
Beta
buf, count, mark, pos| Constructor and Description |
|---|
TestableByteArrayInputStream(byte[] buf)
|
TestableByteArrayInputStream(byte[] buf, int offset, int length)
|
| Modifier and Type | Method and Description |
|---|---|
void |
close()
|
byte[] |
getBuffer()
Returns the written buffer value as a modifiable byte array.
|
boolean |
isClosed()
Returns whether the output stream has been closed.
|
available, mark, markSupported, read, read, reset, skipreadpublic TestableByteArrayInputStream(byte[] buf)
buf - buffer
public TestableByteArrayInputStream(byte[] buf,
int offset,
int length)
buf - buffer
offset - offset in the buffer of the first byte to read
length - maximum number of bytes to read from the buffer
public void close()
throws IOException
Overriding is supported, but overriding method must call the super implementation.
close in interface
Closeable
close in interface
AutoCloseable
close in class
ByteArrayInputStream
IOException
public final byte[] getBuffer()
public final boolean isClosed()