| |
|
| java.lang.Object org.pdfbox.io.NBitInputStream
NBitInputStream | public class NBitInputStream (Code) | | This is an n-bit input stream. This means that you can read chunks of data
as any number of bits, not just 8 bits like the regular input stream. Just set the
number of bits that you would like to read on each call. The default is 8.
author: Ben Litchfield version: $Revision: 1.4 $ |
Method Summary | |
public int | getBitsInChunk() Getter for property bitsToRead. | public long | read() This will read the next n bits from the stream and return the unsigned
value of those bits. | public void | setBitsInChunk(int bitsInChunkValue) Setter for property bitsToRead. | public void | unread(long data) This will unread some data. |
NBitInputStream | public NBitInputStream(InputStream is)(Code) | | Constructor.
Parameters: is - The input stream to read from. |
getBitsInChunk | public int getBitsInChunk()(Code) | | Getter for property bitsToRead.
Value of property bitsToRead. |
read | public long read() throws IOException(Code) | | This will read the next n bits from the stream and return the unsigned
value of those bits.
The next n bits from the stream. throws: IOException - If there is an error reading from the underlying stream. |
setBitsInChunk | public void setBitsInChunk(int bitsInChunkValue)(Code) | | Setter for property bitsToRead.
Parameters: bitsInChunkValue - New value of property bitsToRead. |
unread | public void unread(long data)(Code) | | This will unread some data.
Parameters: data - The data to put back into the stream. |
|
|
|