Closeable, AutoCloseablepublic static class ObjectStream.SmallStream extends ObjectStream
ObjectLoader implementations can use this stream type when the object's content is small enough to be accessed as a single byte array, but the application has still requested it in stream format.
ObjectStream.Filter, ObjectStream.SmallStream| Constructor | Description |
|---|---|
SmallStream(int type,
byte[] data) |
Create the stream from an existing byte array and type.
|
SmallStream(ObjectLoader loader) |
Create the stream from an existing loader's cached bytes.
|
| Modifier and Type | Method | Description |
|---|---|---|
int |
available() |
|
long |
getSize() |
|
int |
getType() |
|
void |
mark(int readlimit) |
|
boolean |
markSupported() |
|
int |
read() |
|
int |
read(byte[] b,
int off,
int len) |
|
void |
reset() |
|
long |
skip(long n) |
close, read, readAllBytes, readNBytes, transferTopublic SmallStream(ObjectLoader loader)
loader - the loader.public SmallStream(int type,
byte[] data)
type - the type constant for the object.data - the fully inflated content of the object.public int getType()
getType in class ObjectStreamConstants.public long getSize()
getSize in class ObjectStreampublic int available()
available in class InputStreampublic long skip(long n)
skip in class InputStreampublic int read()
read in class InputStreampublic int read(byte[] b,
int off,
int len)
read in class InputStreampublic boolean markSupported()
markSupported in class InputStreampublic void mark(int readlimit)
mark in class InputStreampublic void reset()
reset in class InputStreamCopyright © 2018. All rights reserved.