pub struct MapOwned { /* private fields */ }Expand description
CBOR Map with owned keys and values
Implementations
sourceimpl MapOwned
impl MapOwned
pub fn len(&self) -> usize
pub fn iter<'a>(&'a self) -> impl Iterator<Item = (Reader<'a>, Reader<'a>)>
pub fn keys<'a>(&'a self) -> impl Iterator<Item = Reader<'a>>
pub fn values<'a>(&'a self) -> impl Iterator<Item = Reader<'a>>
pub fn to_vec<F, G, K: Decode, V: Decode>(
&self,
f: F,
g: G
) -> Result<Vec<(K, V)>, DecodeError> where
F: for<'b> Fn(&mut Reader<'b>) -> Result<K, DecodeError>,
G: for<'b> Fn(&mut Reader<'b>) -> Result<V, DecodeError>,
pub fn borrow<'a>(&'a self) -> Map<'a>
Trait Implementations
Auto Trait Implementations
impl RefUnwindSafe for MapOwned
impl Send for MapOwned
impl Sync for MapOwned
impl Unpin for MapOwned
impl UnwindSafe for MapOwned
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcefn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
🔬 This is a nightly-only experimental API. (
toowned_clone_into)Uses borrowed data to replace owned data, usually by cloning. Read more