Class Base64EncodeStream
- java.lang.Object
-
- java.io.OutputStream
-
- java.io.FilterOutputStream
-
- de.erichseifert.vectorgraphics2d.util.Base64EncodeStream
-
- All Implemented Interfaces:
java.io.Closeable,java.io.Flushable,java.lang.AutoCloseable
public class Base64EncodeStream extends java.io.FilterOutputStream
-
-
Constructor Summary
Constructors Constructor Description Base64EncodeStream(java.io.OutputStream out)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description voidclose()private intencodeChunk(long uint32, int padByteCount)private static longtoUInt32(byte[] bytes, int size)private static longtoUnsignedInt(long x)voidwrite(int b)private voidwriteChunk()
-
-
-
Field Detail
-
BASE
private static final int BASE
- See Also:
- Constant Field Values
-
POW_64
private static final int[] POW_64
-
CHAR_MAP
private static final char[] CHAR_MAP
-
closed
private boolean closed
-
data
private final byte[] data
-
dataSize
private int dataSize
-
encoded
private final byte[] encoded
-
-
Method Detail
-
write
public void write(int b) throws java.io.IOException- Overrides:
writein classjava.io.FilterOutputStream- Throws:
java.io.IOException
-
writeChunk
private void writeChunk() throws java.io.IOException- Throws:
java.io.IOException
-
toUInt32
private static long toUInt32(byte[] bytes, int size)
-
toUnsignedInt
private static long toUnsignedInt(long x)
-
encodeChunk
private int encodeChunk(long uint32, int padByteCount)
-
close
public void close() throws java.io.IOException- Specified by:
closein interfacejava.lang.AutoCloseable- Specified by:
closein interfacejava.io.Closeable- Overrides:
closein classjava.io.FilterOutputStream- Throws:
java.io.IOException
-
-