Trait minicbor::encode::Encode [−][src]
A type that can be encoded to CBOR.
If this type’s CBOR encoding is meant to be decoded by Decode
impls
derived with minicbor_derive
it is advisable to only produce a
single CBOR data item. Tagging, maps or arrays can and should be used
for multiple values.
Required methods
fn encode<W: Write>(&self, e: &mut Encoder<W>) -> Result<(), Error<W::Error>>
[src]
Encode a value of this type using the given Encoder
.
Implementations on Foreign Types
impl<T: Encode + ?Sized> Encode for &T
[src]
impl<T: Encode + ?Sized> Encode for &mut T
[src]
impl<T: Encode + ?Sized> Encode for Box<T>
[src]
impl Encode for str
[src]
impl<T: Encode> Encode for Option<T>
[src]
impl Encode for String
[src]
impl<T: ?Sized> Encode for Cow<'_, T> where
T: Encode + ToOwned,
[src]
T: Encode + ToOwned,
impl<K, V> Encode for HashMap<K, V> where
K: Encode + Eq + Hash,
V: Encode,
[src]
K: Encode + Eq + Hash,
V: Encode,
impl<K, V> Encode for BTreeMap<K, V> where
K: Encode + Eq + Ord,
V: Encode,
[src]
K: Encode + Eq + Ord,
V: Encode,