public class ByteCountInputStream extends ByteOrderInputStream
little
BIT_MASK, FIELD_MASK, MASK_SIZE, ONES, ZERO
Constructor and Description |
---|
ByteCountInputStream(InputStream in,
boolean littleEndian,
int stackDepth)
Create a Byte Count input stream from given stream
|
Modifier and Type | Method and Description |
---|---|
long |
getLength() |
byte[] |
popBuffer()
Pops the buffer from the stack and returns leftover bytes in a byte array
|
void |
pushBuffer(int len)
Push the current buffer to the stack
|
int |
read() |
readAsciiZString, readBoolean, readByte, readByte, readChar, readDouble, readFloat, readFully, readFully, readInt, readInt, readLine, readLong, readShort, readShort, readString, readUnsignedByte, readUnsignedByte, readUnsignedInt, readUnsignedInt, readUnsignedShort, readUnsignedShort, readUTF, skipBytes
byteAlign, fetchByte, readBitFlag, readFBits, readSBits, readUBits
skip, startDecompressing
read
available, close, mark, markSupported, read, reset
public ByteCountInputStream(InputStream in, boolean littleEndian, int stackDepth)
in
- stream to read fromlittleEndian
- true if stream should be little endianstackDepth
- maximum number of buffers used while readingpublic int read() throws IOException
read
in class DecompressableInputStream
IOException
public void pushBuffer(int len)
len
- number of bytes that can be read from the current bufferpublic byte[] popBuffer() throws IOException
IOException
- if read failspublic long getLength()
Copyright © 2016. All rights reserved.