pub struct MapElement {
pub key: MsgPack,
pub value: MsgPack,
}Expand description
Represents an element in a MessagePack map
use msgpack_simple::{MsgPack, MapElement};
let map = MsgPack::Map(vec![
MapElement {
key: MsgPack::String("foo".to_string()),
value: MsgPack::String("bar".to_string())
}
]);Fields§
§key: MsgPack§value: MsgPackTrait Implementations§
Source§impl Clone for MapElement
impl Clone for MapElement
Source§fn clone(&self) -> MapElement
fn clone(&self) -> MapElement
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for MapElement
impl Debug for MapElement
Source§impl PartialEq for MapElement
impl PartialEq for MapElement
impl StructuralPartialEq for MapElement
Auto Trait Implementations§
impl Freeze for MapElement
impl RefUnwindSafe for MapElement
impl Send for MapElement
impl Sync for MapElement
impl Unpin for MapElement
impl UnwindSafe for MapElement
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