public class Codec extends Object
| Constructor and Description |
|---|
Codec() |
| Modifier and Type | Method and Description |
|---|---|
static String |
byteToHexString(byte[] bytes)
Write a byte array as hexadecimal String.
|
static byte[] |
decodeBASE64(String value)
Decode a base64 value
|
static String |
encodeBASE64(byte[] value)
Encode binary data to base64
|
static String |
encodeBASE64(String value)
Encode a String to base64
|
static String |
hexMD5(String value)
Build an hexadecimal MD5 hash for a String
|
static String |
hexSHA1(String value)
Build an hexadecimal SHA1 hash for a String
|
static byte[] |
hexStringToByte(String hexString)
Transform an hexadecimal String to a byte array.
|
static String |
UUID() |
public static String UUID()
public static String encodeBASE64(String value)
value - The plain Stringpublic static String encodeBASE64(byte[] value)
value - The binary datapublic static byte[] decodeBASE64(String value)
value - The base64 encoded Stringpublic static String hexMD5(String value)
value - The String to hashpublic static String hexSHA1(String value)
value - The String to hashpublic static String byteToHexString(byte[] bytes)
public static byte[] hexStringToByte(String hexString)
Guillaume Bort & zenexity - Distributed under Apache 2 licence, without any warrantly