public class EncodingBase64InputStream extends Object
Base64 encoding is defined in Internet RFC 3548, found at http://tools.ietf.org/html/rfc3548 (among other places).
| Modifier and Type | Field and Description |
|---|---|
static int |
DEFAULT_BUFFER_SIZE |
| Constructor and Description |
|---|
EncodingBase64InputStream(InputStream stream) |
EncodingBase64InputStream(InputStream stream,
int bufferSize) |
public static final int DEFAULT_BUFFER_SIZE
public EncodingBase64InputStream(InputStream stream)
stream - the source of data bytes to be encoded.public EncodingBase64InputStream(InputStream stream, int bufferSize)
stream - the source of data bytes to be encoded.bufferSize - the maximum number of bytes to read at one time.IllegalArgumentException - if bufferSize is not between 10 and 1,000,000.public String read(int maxStringLength) throws IOException
maxStringLength - the resulting String will be no longer than this.IllegalArgumentException - if maxStringLength is less than 4.IllegalStateException - if called after the stream is closed.IOException - from inner InputStream.public void close()
throws IOException
IOException - from the inner InputStreamCopyright © 2013 DuraSpace. All Rights Reserved.