pub struct BytesCbor<T> { /* private fields */ }Expand description
A CBOR byte string where the bytes represent a CBOR representation of the underlying type.
It is assigned a CBOR tag value of 24 as specified in section 8.1 of ISO/IEC
18013-5:2021.
Implementations§
Source§impl<T> BytesCbor<T>
impl<T> BytesCbor<T>
Sourcepub fn try_from_cbor(value: &Value) -> Result<Self, String>where
T: DeserializeOwned,
pub fn try_from_cbor(value: &Value) -> Result<Self, String>where
T: DeserializeOwned,
Trait Implementations§
Source§impl<'de, T> Deserialize<'de> for BytesCbor<T>where
T: DeserializeOwned,
impl<'de, T> Deserialize<'de> for BytesCbor<T>where
T: DeserializeOwned,
Source§fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where
D: Deserializer<'de>,
fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where
D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl<T> StructuralPartialEq for BytesCbor<T>
Auto Trait Implementations§
impl<T> Freeze for BytesCbor<T>where
T: Freeze,
impl<T> RefUnwindSafe for BytesCbor<T>where
T: RefUnwindSafe,
impl<T> Send for BytesCbor<T>where
T: Send,
impl<T> Sync for BytesCbor<T>where
T: Sync,
impl<T> Unpin for BytesCbor<T>where
T: Unpin,
impl<T> UnsafeUnpin for BytesCbor<T>where
T: UnsafeUnpin,
impl<T> UnwindSafe for BytesCbor<T>where
T: UnwindSafe,
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more