@@ -219,6 +219,7 @@ public Base64() {
219219 *
220220 * @param urlSafe
221221 * true if URL-SAFE encoding should be performed. In most situations this should be set to false.
222+ * @since 1.4
222223 */
223224 public Base64 (boolean urlSafe ) {
224225 this (CHUNK_SIZE , CHUNK_SEPARATOR , urlSafe );
@@ -236,6 +237,7 @@ public Base64(boolean urlSafe) {
236237 * @param lineLength
237238 * each line of encoded data will be at most this long (rounded up to nearest multiple of 4). If
238239 * lineLength <= 0, then the output will not be divided into lines (chunks). Ignored when decoding.
240+ * @since 1.4
239241 */
240242 public Base64 (int lineLength ) {
241243 this (lineLength , CHUNK_SEPARATOR );
@@ -257,6 +259,7 @@ public Base64(int lineLength) {
257259 * Each line of encoded data will end with this sequence of bytes.
258260 * @throws IllegalArgumentException
259261 * The provided lineSeparator included some base64 characters. That's not going to work!
262+ * @since 1.4
260263 */
261264 public Base64 (int lineLength , byte [] lineSeparator ) {
262265 this (lineLength , lineSeparator , false );
@@ -283,6 +286,7 @@ public Base64(int lineLength, byte[] lineSeparator) {
283286 *
284287 * @throws IllegalArgumentException The provided lineSeparator included
285288 * some base64 characters. That's not going to work!
289+ * @since 1.4
286290 */
287291 public Base64 (int lineLength , byte [] lineSeparator , boolean urlSafe ) {
288292 this .lineLength = lineLength ;
@@ -310,6 +314,7 @@ public Base64(int lineLength, byte[] lineSeparator, boolean urlSafe) {
310314 * Returns our current encode mode. True if we're URL-SAFE, false otherwise.
311315 *
312316 * @return true if we're in URL-SAFE mode, false otherwise.
317+ * @since 1.4
313318 */
314319 public boolean isUrlSafe () {
315320 return this .encodeTable == URL_SAFE_ENCODE_TABLE ;
@@ -549,6 +554,7 @@ void decode(byte[] in, int inPos, int inAvail) {
549554 * @param octet
550555 * The value to test
551556 * @return <code>true</code> if the value is defined in the the base 64 alphabet, <code>false</code> otherwise.
557+ * @since 1.4
552558 */
553559 public static boolean isBase64 (byte octet ) {
554560 return octet == PAD || (octet >= 0 && octet < DECODE_TABLE .length && DECODE_TABLE [octet ] != -1 );
@@ -606,6 +612,7 @@ public static byte[] encodeBase64(byte[] binaryData) {
606612 * @param binaryData
607613 * binary data to encode
608614 * @return Base64 characters
615+ * @since 1.4
609616 */
610617 public static byte [] encodeBase64URLSafe (byte [] binaryData ) {
611618 return encodeBase64 (binaryData , false , true );
@@ -678,6 +685,7 @@ public static byte[] encodeBase64(byte[] binaryData, boolean isChunked) {
678685 * @return Base64-encoded data.
679686 * @throws IllegalArgumentException
680687 * Thrown when the input array needs an output array bigger than {@link Integer#MAX_VALUE}
688+ * @since 1.4
681689 */
682690 public static byte [] encodeBase64 (byte [] binaryData , boolean isChunked , boolean urlSafe ) {
683691 if (binaryData == null || binaryData .length == 0 ) {
@@ -842,6 +850,7 @@ public byte[] encode(byte[] pArray) {
842850 *
843851 * @param pArray a byte array containing base64 character data
844852 * @return A BigInteger
853+ * @since 1.4
845854 */
846855 public static BigInteger decodeInteger (byte [] pArray ) {
847856 return new BigInteger (1 , decodeBase64 (pArray ));
@@ -854,6 +863,7 @@ public static BigInteger decodeInteger(byte[] pArray) {
854863 * @param bigInt a BigInteger
855864 * @return A byte array containing base64 character data
856865 * @throws NullPointerException if null is passed in
866+ * @since 1.4
857867 */
858868 public static byte [] encodeInteger (BigInteger bigInt ) {
859869 if (bigInt == null ) {
0 commit comments