Class BitInputStream
java.lang.Object
java.io.InputStream
java.io.FilterInputStream
org.apache.commons.imaging.formats.tiff.datareaders.BitInputStream
- All Implemented Interfaces:
Closeable, AutoCloseable
Input stream reading 1-8, 16, 24 or 32 bits, starting from the most significant bit, but incapable of reading non-aligned and invalid input: '<' 8 bit fields across byte
boundaries.
-
Field Summary
FieldsFields inherited from class FilterInputStream
in -
Constructor Summary
Constructors -
Method Summary
Methods inherited from class FilterInputStream
available, close, mark, markSupported, read, read, reset, skip
-
Field Details
-
byteOrder
-
cache
private int cache -
cacheBitsRemaining
private int cacheBitsRemaining -
bytesRead
private long bytesRead
-
-
Constructor Details
-
BitInputStream
BitInputStream(InputStream is, ByteOrder byteOrder)
-
-
Method Details
-
flushCache
public void flushCache() -
getBytesRead
public long getBytesRead() -
read
- Overrides:
readin classFilterInputStream- Throws:
IOException
-
readBits
- Throws:
IOException
-