Modifier and Type | Class and Description |
---|---|
private static class |
Base64Codec.LazyHolder |
Modifier and Type | Field and Description |
---|---|
private byte[] |
alphabets |
private static int |
MASK_2BITS |
private static int |
MASK_4BITS |
private static int |
MASK_6BITS |
private static int |
OFFSET_OF_0 |
private static int |
OFFSET_OF_a |
private static int |
OFFSET_OF_PLUS |
private static int |
OFFSET_OF_SLASH |
private static byte |
PAD |
Modifier | Constructor and Description |
---|---|
(package private) |
Base64Codec() |
protected |
Base64Codec(byte[] alphabets) |
Modifier and Type | Method and Description |
---|---|
byte[] |
decode(byte[] src,
int length) |
(package private) void |
decode1to3bytes(int n,
byte[] src,
int s,
byte[] dest,
int d) |
(package private) void |
decode4bytes(byte[] src,
int s,
byte[] dest,
int d) |
byte[] |
encode(byte[] src) |
(package private) void |
encode1byte(byte[] src,
int s,
byte[] dest,
int d) |
(package private) void |
encode2bytes(byte[] src,
int s,
byte[] dest,
int d) |
(package private) void |
encode3bytes(byte[] src,
int s,
byte[] dest,
int d) |
protected int |
pos(byte in) |
private static final int OFFSET_OF_a
private static final int OFFSET_OF_0
private static final int OFFSET_OF_PLUS
private static final int OFFSET_OF_SLASH
private static final int MASK_2BITS
private static final int MASK_4BITS
private static final int MASK_6BITS
private static final byte PAD
private final byte[] alphabets
void encode3bytes(byte[] src, int s, byte[] dest, int d)
void encode2bytes(byte[] src, int s, byte[] dest, int d)
void encode1byte(byte[] src, int s, byte[] dest, int d)
void decode4bytes(byte[] src, int s, byte[] dest, int d)
void decode1to3bytes(int n, byte[] src, int s, byte[] dest, int d)
n
- the number of final quantum in bytes to decode into. Ranges from 1 to 3, inclusive.protected int pos(byte in)