Trait oasis_cbor::decode::Decode

source ·
pub trait Decode {
    fn try_from_cbor_value(value: Value) -> Result<Self, DecodeError>
    where
        Self: Sized
; fn try_default() -> Result<Self, DecodeError>
    where
        Self: Sized
, { ... } fn try_from_cbor_value_default(value: Value) -> Result<Self, DecodeError>
    where
        Self: Sized
, { ... } }
Expand description

Trait for types that can be decoded from CBOR.

Required Methods

Try to decode from a given CBOR value.

Provided Methods

Try to decode from a missing/null/undefined value.

Try to decode from a given CBOR value, calling try_default in case the value is null or undefined.

Implementations on Foreign Types

Implementors