| Modifier and Type | Field and Description |
|---|---|
| private static final String | |
| private static final String | |
| private static final String | |
| private static final char[] | |
| private static final char[] |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public static byte[] | Returns: the decoded bytes as an arraythe string to be decoded value)Decode the String from Base64 into a byte array. |
| private static byte[] | |
| public static byte[] | Returns: the decoded bytes as an arraythe string to be decoded value)Decodes a Base64 URL and Filename Safe encoded String into a byte array. |
| public static byte[] | |
| public static String | Returns: digested valuethe name of the algorithm requested, e.g. MD5, SHA-1, SHA-256, etc. algorithm)digest the CharSequence instance |
| public static String | |
| public static Writable | Returns: object which will write the Base64 encoding of the byte arrayByte array to be encoded data, final boolean whether or not the Base64 encoded data should be MIME chunked chunked)Produce a Writable object which writes the Base64 encoding of the byte array. |
| public static Writable | Returns: object which will write the Base64 encoding of the byte arrayByte array to be encoded data)Produce a Writable object which writes the Base64 encoding of the byte array. |
| public static Writable | Returns: object which will write the Base64 encoding of the byte arraybyte array to be encoded data, final boolean whether or not the Base64 encoded data should be MIME chunked chunked)Produce a Writable object which writes the Base64 encoding of the byte array. |
| private static Writable | |
| public static Writable | Returns: object which will write the Base64 encoding of the byte arraybyte array to be encoded data)Produce a Writable object which writes the Base64 encoding of the byte array. |
| public static Writable | Returns: object which will write the Base64 URL and Filename Safe encoding of the byte arrayByte array to be encoded data)Produce a Writable object which writes the Base64 URL and Filename Safe encoding of the byte array. |
| public static Writable | Returns: object which will write the Base64 URL and Filename Safe encoding of the byte arrayByte array to be encoded data, boolean whether or not the encoded data should be padded pad)Produce a Writable object which writes the Base64 URL and Filename Safe encoding of the byte array. |
| public static Writable | Returns: object which will write the Base64 URL and Filename Safe encoding of the byte arrayByte array to be encoded data)Produce a Writable object which writes the Base64 URL and Filename Safe encoding of the byte array. |
| public static Writable | Returns: object which will write the Base64 URL and Filename Safe encoding of the byte arrayByte array to be encoded data, final boolean whether or not the encoded data should be padded pad)Produce a Writable object which writes the Base64 URL and Filename Safe encoding of the byte array. |
| public static Writable | |
| public static Writable | Returns: object which will write the hex encoding of the byte arraybyte array to be encoded data)Produces a Writable that writes the hex encoding of the byte[]. |
| public static String | |
| public static String | |
| public static String | |
| public static String |
| CHUNK_SEPARATOR | back to summary |
|---|---|
| private static final String CHUNK_SEPARATOR | |
| MD5 | back to summary |
|---|---|
| private static final String MD5 | |
| SHA_256 | back to summary |
|---|---|
| private static final String SHA_256 | |
| T_TABLE | back to summary |
|---|---|
| private static final char[] T_TABLE | |
| T_TABLE_URLSAFE | back to summary |
|---|---|
| private static final char[] T_TABLE_URLSAFE | |
| EncodingGroovyMethods | back to summary |
|---|---|
| public EncodingGroovyMethods() | |
| decodeBase64 | back to summary |
|---|---|
| public static byte[] decodeBase64(String value) Decode the String from Base64 into a byte array.
| |
| decodeBase64 | back to summary |
|---|---|
| private static byte[] decodeBase64(String value, boolean urlSafe) | |
| decodeBase64Url | back to summary |
|---|---|
| public static byte[] decodeBase64Url(String value) Decodes a Base64 URL and Filename Safe encoded String into a byte array.
| |
| decodeHex | back to summary |
|---|---|
| public static byte[] decodeHex(final String value) Decodes a hex string to a byte array. The hex string can contain either upper case or lower case letters.
| |
| digest | back to summary |
|---|---|
| public static String digest(CharSequence self, String algorithm) throws NoSuchAlgorithmException digest the CharSequence instance
| |
| digest | back to summary |
|---|---|
| public static String digest(byte[] self, String algorithm) throws NoSuchAlgorithmException digest the byte array
| |
| encodeBase64 | back to summary |
|---|---|
| public static Writable encodeBase64(Byte[] data, final boolean chunked) Produce a Writable object which writes the Base64 encoding of the byte array.
Calling toString() on the result returns the encoding as a String. For more
information on Base64 encoding and chunking see | |
| encodeBase64 | back to summary |
|---|---|
| public static Writable encodeBase64(Byte[] data) Produce a Writable object which writes the Base64 encoding of the byte array.
Calling toString() on the result returns the encoding as a String. For more
information on Base64 encoding and chunking see | |
| encodeBase64 | back to summary |
|---|---|
| public static Writable encodeBase64(final byte[] data, final boolean chunked) Produce a Writable object which writes the Base64 encoding of the byte array.
Calling toString() on the result returns the encoding as a String. For more
information on Base64 encoding and chunking see
| |
| encodeBase64 | back to summary |
|---|---|
| private static Writable encodeBase64(final byte[] data, final boolean chunked, final boolean urlSafe, final boolean pad) | |
| encodeBase64 | back to summary |
|---|---|
| public static Writable encodeBase64(final byte[] data) Produce a Writable object which writes the Base64 encoding of the byte array.
Calling toString() on the result returns the encoding as a String. For more
information on Base64 encoding and chunking see
| |
| encodeBase64Url | back to summary |
|---|---|
| public static Writable encodeBase64Url(Byte[] data) Produce a Writable object which writes the Base64 URL and Filename Safe encoding of the byte array.
Calling toString() on the result returns the encoding as a String. For more
information on Base64 URL and Filename Safe encoding see
The method omits padding and is equivalent to calling
| |
| encodeBase64Url | back to summary |
|---|---|
| public static Writable encodeBase64Url(Byte[] data, boolean pad) Produce a Writable object which writes the Base64 URL and Filename Safe encoding of the byte array.
Calling toString() on the result returns the encoding as a String. For more
information on Base64 URL and Filename Safe encoding see | |
| encodeBase64Url | back to summary |
|---|---|
| public static Writable encodeBase64Url(final byte[] data) Produce a Writable object which writes the Base64 URL and Filename Safe encoding of the byte array.
Calling toString() on the result returns the encoding as a String. For more
information on Base64 URL and Filename Safe encoding see
The method omits padding and is equivalent to calling
| |
| encodeBase64Url | back to summary |
|---|---|
| public static Writable encodeBase64Url(final byte[] data, final boolean pad) Produce a Writable object which writes the Base64 URL and Filename Safe encoding of the byte array.
Calling toString() on the result returns the encoding as a String. For more
information on Base64 URL and Filename Safe encoding see
| |
| encodeHex | back to summary |
|---|---|
| public static Writable encodeHex(final Byte[] data) Produces a Writable that writes the hex encoding of the Byte[]. Calling toString() on this Writable returns the hex encoding as a String. The hex encoding includes two characters for each byte and all letters are lower case.
| |
| encodeHex | back to summary |
|---|---|
| public static Writable encodeHex(final byte[] data) Produces a Writable that writes the hex encoding of the byte[]. Calling toString() on this Writable returns the hex encoding as a String. The hex encoding includes two characters for each byte and all letters are lower case.
| |
| md5 | back to summary |
|---|---|
| public static String md5(CharSequence self) throws NoSuchAlgorithmException Calculate md5 of the CharSequence instance
| |
| md5 | back to summary |
|---|---|
| public static String md5(byte[] self) throws NoSuchAlgorithmException Calculate md5 of the byte array
| |
| sha256 | back to summary |
|---|---|
| public static String sha256(CharSequence self) throws NoSuchAlgorithmException Calculate SHA-256 of the CharSequence instance
| |
| sha256 | back to summary |
|---|---|
| public static String sha256(byte[] self) throws NoSuchAlgorithmException Calculate SHA-256 of the byte array
| |