public class Base64Coder
extends java.lang.Object
Constructor and Description |
---|
Base64Coder() |
Modifier and Type | Method and Description |
---|---|
static byte[] |
decode(char[] in)
Decodes Base64 data.
|
static java.lang.String |
decode(java.lang.String s)
Decodes a Base64 string.
|
static char[] |
encode(byte[] in)
Encodes a byte array into Base64 format.
|
static java.lang.String |
encode(java.lang.String s)
Encodes a string into Base64 format.
|
public static java.lang.String encode(java.lang.String s)
s
- a String to be encoded.public static char[] encode(byte[] in)
in
- an array containing the data bytes to be encoded.public static java.lang.String decode(java.lang.String s)
s
- a Base64 String to be decoded.java.lang.IllegalArgumentException
- if the input is not valid Base64 encoded data.public static byte[] decode(char[] in)
in
- a character array containing the Base64 encoded data.java.lang.IllegalArgumentException
- if the input is not valid Base64 encoded data.