public class Base64 extends Object
This array is a lookup table that translates 6-bit positive integer index values into their "Base64 Alphabet" equivalents as specified in "Table 1: The Base64 Alphabet" of RFC 2045 (and RFC 4648). 'A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O', 'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W', 'X', 'Y', 'Z', 'a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o', 'p', 'q', 'r', 's', 't', 'u', 'v', 'w', 'x', 'y', 'z', '0', '1', '2', '3', '4', '5', '6', '7', '8', '9', '+', '/' It's the lookup table for "URL and Filename safe Base64" as specified in Table 2 of the RFC 4648, with the '+' and '/' changed to '-' and '_'. This table is used when BASE64_URL is specified. 'A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O', 'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W', 'X', 'Y', 'Z', 'a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o', 'p', 'q', 'r', 's', 't', 'u', 'v', 'w', 'x', 'y', 'z', '0', '1', '2', '3', '4', '5', '6', '7', '8', '9', '-', '_'
Base64| Constructor and Description |
|---|
Base64() |
| Modifier and Type | Method and Description |
|---|---|
static @NotNull String |
de2str(@Nullable byte[] bytes) |
static @NotNull String |
de2str(@Nullable InputStream ins) |
static @NotNull String |
de2str(@Nullable String str) |
static @NotNull byte[] |
decode(@Nullable byte[] bytes) |
static @NotNull byte[] |
decode(@Nullable InputStream ins) |
static @NotNull byte[] |
decode(@Nullable String str) |
static @NotNull String |
encode(@Nullable byte[] bytes) |
static @NotNull String |
encode(@Nullable byte[] bytes,
boolean urlSafe) |
static @NotNull String |
encode(@Nullable InputStream ins) |
static @NotNull String |
encode(@Nullable InputStream ins,
boolean urlSafe) |
static @NotNull String |
encode(@Nullable String str) |
static @NotNull String |
encode(@Nullable String str,
boolean urlSafe) |
static Base64.Encoder |
getEncoder(boolean urlSafe) |
public static Base64.Encoder getEncoder(boolean urlSafe)
@NotNull public static @NotNull String encode(@Nullable @Nullable InputStream ins)
@NotNull public static @NotNull String encode(@Nullable @Nullable byte[] bytes)
@NotNull public static @NotNull String encode(@Nullable @Nullable String str, boolean urlSafe)
@NotNull public static @NotNull String encode(@Nullable @Nullable InputStream ins, boolean urlSafe)
@NotNull public static @NotNull String encode(@Nullable @Nullable byte[] bytes, boolean urlSafe)
@NotNull public static @NotNull String de2str(@Nullable @Nullable byte[] bytes)
@NotNull public static @NotNull String de2str(@Nullable @Nullable InputStream ins)
@NotNull
public static @NotNull byte[] decode(@Nullable
@Nullable String str)
@NotNull
public static @NotNull byte[] decode(@Nullable
@Nullable byte[] bytes)
@NotNull
public static @NotNull byte[] decode(@Nullable
@Nullable InputStream ins)
Copyright © 2020. All rights reserved.