pub struct Reader<'a> { /* private fields */ }
Expand description

CBOR Data structure to read CBOR elements from a slice of byte

Implementations

Return the number of bytes remaining to be processed by the reader

Return the number of bytes consumed since the start of the Reader

Return if all the bytes have been consumed by the reader

Assume the reader is finished (no more bytes to process), or otherwise return a ReaderError::NotTerminated

Peek at the next type in the buffer

Note that it can still return error if there’s no data available (end of buffer), or that the CBOR lead byte is not well-formed

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.