Type Definition ssh_encoding::Base64Reader

source ·
pub type Base64Reader<'i> = Decoder<'i, Base64>;
Available on crate feature base64 only.
Expand description

Constant-time Base64 reader implementation.

Trait Implementations§

source§

impl Reader for Base64Reader<'_>

source§

fn read<'o>(&mut self, out: &'o mut [u8]) -> Result<&'o [u8]>

Read as much data as is needed to exactly fill out. Read more
source§

fn remaining_len(&self) -> usize

Get the length of the remaining data after Base64 decoding.
source§

fn is_finished(&self) -> bool

Is decoding finished?
source§

fn read_prefixed<'r, T, E, F>(&'r mut self, f: F) -> Result<T, E>where E: From<Error>, F: FnOnce(&mut NestedReader<'r, Self>) -> Result<T, E>,

Decode length-prefixed data. Read more
source§

fn read_byten<'o>(&mut self, out: &'o mut [u8]) -> Result<&'o [u8]>

Decodes [u8] from byte[n] as described in RFC4251 § 5: Read more
source§

fn read_string<'o>(&mut self, buf: &'o mut [u8]) -> Result<&'o str>

Decode a string as described in RFC4251 § 5: Read more
source§

fn drain(&mut self, n_bytes: usize) -> Result<()>

Drain the given number of bytes from the reader, discarding them.
source§

fn drain_prefixed(&mut self) -> Result<usize>

Decode a u32 length prefix, and then drain the length of the body. Read more
source§

fn finish<T>(self, value: T) -> Result<T>

Finish decoding, returning the given value if there is no remaining data, or an error otherwise.