@Test public void testUrlSafe() { for (int i = 0; i <= 150; i++) { final byte[][] randomData = Base64TestData.randomData(i, true); final byte[] encoded = randomData[1]; final byte[] decoded = randomData[0]; final byte[] result = Base64.decodeBase64(encoded); assertTrue("url-safe i=" + i, Arrays.equals(decoded, result)); assertFalse("url-safe i=" + i + " no '='", Base64TestData.bytesContain(encoded, (byte) '=')); assertFalse("url-safe i=" + i + " no '\\'", Base64TestData.bytesContain(encoded, (byte) '\\')); assertFalse("url-safe i=" + i + " no '+'", Base64TestData.bytesContain(encoded, (byte) '+')); } }
public static byte[] decodeBase64(final String base64String) { return new Base64().decode(base64String); }
Base64 extends BaseNCodec { public static byte[] decodeBase64(final String base64String) { return new Base64().decode(base64String); } }
Base64 extends BaseNCodec { public static byte[] decodeBase64(final String base64String) { return new Base64().decode(base64String); } Base64();  Base64(final boolean urlSafe);  Base64(final int lineLength);  Base64(final int lineLength, final byte[] lineSeparator);  Base64(final int lineLength, final byte[] lineSeparator, final boolean urlSafe); }
Base64 extends BaseNCodec { public static byte[] decodeBase64(final String base64String) { return new Base64().decode(base64String); } Base64();  Base64(final boolean urlSafe);  Base64(final int lineLength);  Base64(final int lineLength, final byte[] lineSeparator);  Base64(final int lineLength, final byte[] lineSeparator, final boolean urlSafe); boolean isUrlSafe(); @Deprecated static boolean isArrayByteBase64(final byte[] arrayOctet); static boolean isBase64(final byte octet); static boolean isBase64(final String base64); static boolean isBase64(final byte[] arrayOctet); static byte[] encodeBase64(final byte[] binaryData); static String encodeBase64String(final byte[] binaryData); static byte[] encodeBase64URLSafe(final byte[] binaryData); static String encodeBase64URLSafeString(final byte[] binaryData); static byte[] encodeBase64Chunked(final byte[] binaryData); static byte[] encodeBase64(final byte[] binaryData, final boolean isChunked); static byte[] encodeBase64(final byte[] binaryData, final boolean isChunked, final boolean urlSafe); static byte[] encodeBase64(final byte[] binaryData, final boolean isChunked,
                                      final boolean urlSafe, final int maxResultSize); static byte[] decodeBase64(final String base64String); static byte[] decodeBase64(final byte[] base64Data); static BigInteger decodeInteger(final byte[] pArray); static byte[] encodeInteger(final BigInteger bigInt); }
Base64 extends BaseNCodec { public static byte[] decodeBase64(final String base64String) { return new Base64().decode(base64String); } Base64();  Base64(final boolean urlSafe);  Base64(final int lineLength);  Base64(final int lineLength, final byte[] lineSeparator);  Base64(final int lineLength, final byte[] lineSeparator, final boolean urlSafe); boolean isUrlSafe(); @Deprecated static boolean isArrayByteBase64(final byte[] arrayOctet); static boolean isBase64(final byte octet); static boolean isBase64(final String base64); static boolean isBase64(final byte[] arrayOctet); static byte[] encodeBase64(final byte[] binaryData); static String encodeBase64String(final byte[] binaryData); static byte[] encodeBase64URLSafe(final byte[] binaryData); static String encodeBase64URLSafeString(final byte[] binaryData); static byte[] encodeBase64Chunked(final byte[] binaryData); static byte[] encodeBase64(final byte[] binaryData, final boolean isChunked); static byte[] encodeBase64(final byte[] binaryData, final boolean isChunked, final boolean urlSafe); static byte[] encodeBase64(final byte[] binaryData, final boolean isChunked,
                                      final boolean urlSafe, final int maxResultSize); static byte[] decodeBase64(final String base64String); static byte[] decodeBase64(final byte[] base64Data); static BigInteger decodeInteger(final byte[] pArray); static byte[] encodeInteger(final BigInteger bigInt);  }