org.apache.commons.codec.binary
public class BaseNCodecInputStream extends java.io.FilterInputStream
Modifier and Type | Field and Description |
---|---|
private BaseNCodec |
baseNCodec |
private boolean |
doEncode |
private byte[] |
singleByte |
Modifier | Constructor and Description |
---|---|
protected |
BaseNCodecInputStream(java.io.InputStream in,
BaseNCodec baseNCodec,
boolean doEncode) |
Modifier and Type | Method and Description |
---|---|
boolean |
markSupported() |
int |
read()
Reads one
byte from this input stream. |
int |
read(byte[] b,
int offset,
int len)
Attempts to read
len bytes into the specified b array starting at offset
from this InputStream. |
private final boolean doEncode
private final BaseNCodec baseNCodec
private final byte[] singleByte
protected BaseNCodecInputStream(java.io.InputStream in, BaseNCodec baseNCodec, boolean doEncode)
public int read() throws java.io.IOException
byte
from this input stream.read
in class java.io.FilterInputStream
java.io.IOException
- if an I/O error occurs.public int read(byte[] b, int offset, int len) throws java.io.IOException
len
bytes into the specified b
array starting at offset
from this InputStream.read
in class java.io.FilterInputStream
b
- destination byte arrayoffset
- where to start writing the byteslen
- maximum number of bytes to readjava.io.IOException
- if an I/O error occurs.java.lang.NullPointerException
- if the byte array parameter is nulljava.lang.IndexOutOfBoundsException
- if offset, len or buffer size are invalidpublic boolean markSupported()
markSupported
in class java.io.FilterInputStream
commons-codec version 1.6-SNAPSHOT - Copyright © 2002-2016 - Apache Software Foundation