Base64.Decode Method

Definition

Overloads

Decode(Byte[], Base64Flags)

Decode the Base64-encoded data in input and return the data in a new byte array.

Decode(String, Base64Flags)

Decode the Base64-encoded data in input and return the data in a new byte array.

Decode(Byte[], Int32, Int32, Base64Flags)

Decode the Base64-encoded data in input and return the data in a new byte array.

Decode(Byte[], Base64Flags)

Decode the Base64-encoded data in input and return the data in a new byte array.

[Android.Runtime.Register("decode", "([BI)[B", "")]
public static byte[]? Decode (byte[]? input, Android.Util.Base64Flags flags);
[<Android.Runtime.Register("decode", "([BI)[B", "")>]
static member Decode : byte[] * Android.Util.Base64Flags -> byte[]

Parameters

input
Byte[]

the input array to decode

flags
Base64Flags

controls certain features of the decoded output. Pass DEFAULT to decode standard Base64.

Returns

Byte[]
Attributes

Exceptions

if the input contains incorrect padding

Remarks

Decode the Base64-encoded data in input and return the data in a new byte array.

The padding '=' characters at the end are considered optional, but if any are present, there must be the correct number of them.

Java documentation for android.util.Base64.decode(byte[], int).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to

Decode(String, Base64Flags)

Decode the Base64-encoded data in input and return the data in a new byte array.

[Android.Runtime.Register("decode", "(Ljava/lang/String;I)[B", "")]
public static byte[]? Decode (string? str, Android.Util.Base64Flags flags);
[<Android.Runtime.Register("decode", "(Ljava/lang/String;I)[B", "")>]
static member Decode : string * Android.Util.Base64Flags -> byte[]

Parameters

str
String

the input String to decode, which is converted to bytes using the default charset

flags
Base64Flags

controls certain features of the decoded output. Pass DEFAULT to decode standard Base64.

Returns

Byte[]
Attributes

Exceptions

if the input contains incorrect padding

Remarks

Decode the Base64-encoded data in input and return the data in a new byte array.

The padding '=' characters at the end are considered optional, but if any are present, there must be the correct number of them.

Java documentation for android.util.Base64.decode(java.lang.String, int).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to

Decode(Byte[], Int32, Int32, Base64Flags)

Decode the Base64-encoded data in input and return the data in a new byte array.

[Android.Runtime.Register("decode", "([BIII)[B", "")]
public static byte[]? Decode (byte[]? input, int offset, int len, Android.Util.Base64Flags flags);
[<Android.Runtime.Register("decode", "([BIII)[B", "")>]
static member Decode : byte[] * int * int * Android.Util.Base64Flags -> byte[]

Parameters

input
Byte[]

the data to decode

offset
Int32

the position within the input array at which to start

len
Int32

the number of bytes of input to decode

flags
Base64Flags

controls certain features of the decoded output. Pass DEFAULT to decode standard Base64.

Returns

Byte[]
Attributes

Exceptions

if the input contains incorrect padding

Remarks

Decode the Base64-encoded data in input and return the data in a new byte array.

The padding '=' characters at the end are considered optional, but if any are present, there must be the correct number of them.

Java documentation for android.util.Base64.decode(byte[], int, int, int).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to