Javadoc and exception messages: "base 64" -> "Base64". · apache/commons-codec@2df7b9a (original) (raw)
`@@ -601,15 +601,15 @@ public static boolean isArrayByteBase64(final byte[] arrayOctet) {
`
601
601
` }
`
602
602
``
603
603
`/**
`
604
``
`-
- Tests whether or not the {@code octet} is in the base 64 alphabet.
`
``
604
`+
- Tests whether or not the {@code octet} is in the Base64 alphabet.
`
605
605
` *
`
606
606
` * This method threats all characters included within standard base64 and base64url encodings as valid base64 characters. This includes the '+' and '/'
`
607
607
` * (standard base64), as well as '-' and '_' (URL-safe base64) characters. For enforcing verification against strict standard Base64 or Base64 URL-safe
`
608
608
` * tables, please use {@link #isBase64Standard(byte)} or {@link #isBase64Url(byte)} methods respectively.
`
609
609
` *
`
610
610
` *
`
611
611
` * @param octet The value to test.
`
612
``
`-
- @return {@code true} if the value is defined in the base 64 alphabet, {@code false} otherwise.
`
``
612
`+
- @return {@code true} if the value is defined in the Base64 alphabet, {@code false} otherwise.
`
613
613
` * @since 1.4
`
614
614
` */
`
615
615
`public static boolean isBase64(final byte octet) {
`
`@@ -654,14 +654,14 @@ public static boolean isBase64(final String base64) {
`
654
654
` }
`
655
655
``
656
656
`/**
`
657
``
`-
- Tests whether or not the {@code octet} is in the standard base 64 alphabet.
`
``
657
`+
- Tests whether or not the {@code octet} is in the standard Base64 alphabet.
`
658
658
` *
`
659
659
` * This implementation is aligned with RFC 2045 Table 1: The
`
660
660
` * Base64 Alphabet.
`
661
661
` *
`
662
662
` *
`
663
663
` * @param octet The value to test.
`
664
``
`-
- @return {@code true} if the value is defined in the standard base 64 alphabet, {@code false} otherwise.
`
``
664
`+
- @return {@code true} if the value is defined in the standard Base64 alphabet, {@code false} otherwise.
`
665
665
` * @since 1.21
`
666
666
` */
`
667
667
`public static boolean isBase64Standard(final byte octet) {
`
`@@ -705,15 +705,15 @@ public static boolean isBase64Standard(final String base64) {
`
705
705
` }
`
706
706
``
707
707
`/**
`
708
``
`-
- Tests whether or not the {@code octet} is in the URL-safe base 64 alphabet.
`
``
708
`+
- Tests whether or not the {@code octet} is in the URL-safe Base64 alphabet.
`
709
709
` *
`
710
710
` * This implementation is aligned with
`
711
711
` * RFC 4648
`
712
712
` * Table 2: The "URL and Filename safe" Base 64 Alphabet.
`
713
713
` *
`
714
714
` *
`
715
715
` * @param octet The value to test.
`
716
``
`-
- @return {@code true} if the value is defined in the URL-safe base 64 alphabet, {@code false} otherwise.
`
``
716
`+
- @return {@code true} if the value is defined in the URL-safe Base64 alphabet, {@code false} otherwise.
`
717
717
` * @since 1.21
`
718
718
` */
`
719
719
`public static boolean isBase64Url(final byte octet) {
`
`@@ -1164,7 +1164,7 @@ public boolean isUrlSafe() {
`
1164
1164
` }
`
1165
1165
``
1166
1166
`/**
`
1167
``
`-
- Validates whether decoding the final trailing character is possible in the context of the set of possible base 64 values.
`
``
1167
`+
- Validates whether decoding the final trailing character is possible in the context of the set of possible Base64 values.
`
1168
1168
` *
`
1169
1169
` * The character is valid if the lower bits within the provided mask are zero. This is used to test the final trailing base-64 digit is zero in the bits
`
1170
1170
` * that will be discarded.
`
`@@ -1176,10 +1176,8 @@ public boolean isUrlSafe() {
`
1176
1176
` */
`
1177
1177
`private void validateCharacter(final int emptyBitsMask, final Context context) {
`
1178
1178
`if (isStrictDecoding() && (context.ibitWorkArea & emptyBitsMask) != 0) {
`
1179
``
`-
throw new IllegalArgumentException(
`
1180
``
`-
"Strict decoding: Last encoded character (before the paddings if any) is a valid " +
`
1181
``
`-
"base 64 alphabet but not a possible encoding. " +
`
1182
``
`-
"Expected the discarded bits from the character to be zero.");
`
``
1179
`+
throw new IllegalArgumentException("Strict decoding: Last encoded character (before the paddings if any) is a valid "
`
``
1180
`+
- "Base64 alphabet but not a possible encoding. Expected the discarded bits from the character to be zero.");
`
1183
1181
` }
`
1184
1182
` }
`
1185
1183
``
`@@ -1190,10 +1188,8 @@ private void validateCharacter(final int emptyBitsMask, final Context context) {
`
1190
1188
` */
`
1191
1189
`private void validateTrailingCharacter() {
`
1192
1190
`if (isStrictDecoding()) {
`
1193
``
`-
throw new IllegalArgumentException(
`
1194
``
`-
"Strict decoding: Last encoded character (before the paddings if any) is a valid " +
`
1195
``
`-
"base 64 alphabet but not a possible encoding. " +
`
1196
``
`-
"Decoding requires at least two trailing 6-bit characters to create bytes.");
`
``
1191
`+
throw new IllegalArgumentException("Strict decoding: Last encoded character (before the paddings if any) is a valid "
`
``
1192
`+
- "Base64 alphabet but not a possible encoding. Decoding requires at least two trailing 6-bit characters to create bytes.");
`
1197
1193
` }
`
1198
1194
` }
`
1199
1195
``