Struct serde_cbor::de::SliceRead [−][src]
A CBOR input source that reads from a slice of bytes.
Implementations
impl<'a> SliceRead<'a>
[src]
pub fn new(slice: &'a [u8]) -> SliceRead<'a>
[src]
Creates a CBOR input source to read from a slice of bytes.
Trait Implementations
impl<'a> Debug for SliceRead<'a>
[src]
impl<'a> Read<'a> for SliceRead<'a>
[src]
fn next(&mut self) -> Result<Option<u8>>
[src]
fn peek(&mut self) -> Result<Option<u8>>
[src]
fn clear_buffer(&mut self)
[src]
fn read_to_buffer(&mut self, n: usize) -> Result<()>
[src]
fn read<'b>(&'b mut self, n: usize) -> Result<EitherLifetime<'b, 'a>>
[src]
fn take_buffer<'b>(&'b mut self) -> EitherLifetime<'b, 'a>
[src]
fn read_into(&mut self, buf: &mut [u8]) -> Result<()>
[src]
fn discard(&mut self)
[src]
fn offset(&self) -> u64
[src]
Auto Trait Implementations
impl<'a> RefUnwindSafe for SliceRead<'a>
impl<'a> Send for SliceRead<'a>
impl<'a> Sync for SliceRead<'a>
impl<'a> Unpin for SliceRead<'a>
impl<'a> UnwindSafe for SliceRead<'a>
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,