class Base64Codec
extends java.lang.Object
Provides Base64 encoding and decoding.
This class implements Base64 encoding
Thanks to Apache Commons project. This class refactored from org.apache.commons.codec.binary
Original Thanks to commons project in ws.apache.org for this code.
Modifier and Type | Field and Description |
---|---|
private static int |
BYTES_PER_ENCODED_BLOCK |
private static int |
BYTES_PER_UNENCODED_BLOCK |
private static int[] |
DECODE_TABLE |
private static byte[] |
ENCODE_TABLE
This array is a lookup table that translates 6-bit positive integer index values into their "Base64 Alphabet"
equivalents as specified in Table 1 of RFC 2045.
|
private static byte |
PAD
padding char
|
private static int |
SIX_BIT_MASK
Mask used to extract 6 bits, used when encoding
|
Constructor and Description |
---|
Base64Codec() |
Modifier and Type | Method and Description |
---|---|
byte[] |
decode(java.lang.String s) |
java.lang.String |
encode(byte[] in) |
private static final int BYTES_PER_UNENCODED_BLOCK
private static final int BYTES_PER_ENCODED_BLOCK
private static final int SIX_BIT_MASK
private static final byte PAD
private static final byte[] ENCODE_TABLE
private static final int[] DECODE_TABLE