pub struct SimpleCBORWrapper<H: SimpleCBORHandler> { /* private fields */ }
👎Deprecated
Expand description

Wrapper for resource handlers that are implemented in terms of GETting, POSTing or PUTting objects in CBOR format.

The wrapper handles all encoding and decoding, options processing (ignoring the critical Uri-Path option under the assumption that that has been already processed by an underlying request router), the corresponding errors and block-wise GETs.

More complex handlers (eg. implementing additional representations, or processing query aprameters into additional data available to the SimpleCBORHandler) can be built by forwarding to this (where any critical but already processed options would need to be masked from the message’s option) or taking inspiration from it.

Implementations

👎Deprecated

Trait Implementations

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.

👎Deprecated
Divert requests arriving at path into the given handler. Read more

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.