Fields

char_to_index: [256]u8,

e.g. ‘A’ => 0. invalid_char for any value not in the 64 alphabet chars.

pad_char: ?u8,

Functions

fn calcSizeForSlice(decoder: *const Base64Decoder, source: []const u8) Error!usize

Return the exact decoded size for a slice. InvalidPadding is returned if the …

Return the exact decoded size for a slice. InvalidPadding is returned if the input length is not valid.

fn calcSizeUpperBound(decoder: *const Base64Decoder, source_len: usize) Error!usize

Return the maximum possible decoded size for a given input length - The actual l…

Return the maximum possible decoded size for a given input length - The actual length may be less if the input includes padding. InvalidPadding is returned if the input length is not valid.

fn decode(decoder: *const Base64Decoder, dest: []u8, source: []const u8) Error!void

dest.len must be what you get from ::calcSize. invalid characters result in err…

dest.len must be what you get from ::calcSize. invalid characters result in error.InvalidCharacter. invalid padding results in error.InvalidPadding.

fn init(alphabet_chars: [64]u8, pad_char: ?u8) Base64Decoder

No documentation provided.