pub struct Slice<'de> { /* private fields */ }
Expand description
A simple Flavor
representing the deserialization from a borrowed slice
Implementations§
Trait Implementations§
Source§impl<'de> Flavor<'de> for Slice<'de>
impl<'de> Flavor<'de> for Slice<'de>
Source§fn finalize(self) -> Result<&'de [u8]>
fn finalize(self) -> Result<&'de [u8]>
Return the remaining (unused) bytes in the Deserializer
Source§type Remainder = &'de [u8]
type Remainder = &'de [u8]
The remaining data of this flavor after deserializing has completed. Read more
Source§fn size_hint(&self) -> Option<usize>
fn size_hint(&self) -> Option<usize>
Returns the number of bytes remaining in the message, if known. Read more
Source§fn try_take_n(&mut self, ct: usize) -> Result<&'de [u8]>
fn try_take_n(&mut self, ct: usize) -> Result<&'de [u8]>
Attempt to take the next
ct
bytes from the serialized message