Struct cbor::decoder::Kernel [] [src]

pub struct Kernel<R> { /* fields omitted */ }

This decoding kernel reads from an underlying std::io::Read type primitive CBOR values such as unsigned and signed integers as well as raw bytes. It forms the basis on which Decoder and GenericDecoder add logic for handling Tags, heterogenous data and generic value decoding.

Methods

impl<R: ReadBytesExt> Kernel<R>
[src]

Decode first and potentially the following bytes as an unsigned value following the rules of major type 0.

Read begin as the length and return that many raw bytes.

If length is greater than the given max_len, DecodeError::TooLong is returned instead.

impl<R: ReadBytesExt + ReadSlice> Kernel<R>
[src]

Read begin as the length and return that many raw bytes as a slice.

If length is greater than the given max_len, DecodeError::TooLong is returned instead.