pub enum Value {
Nil,
Bool(bool),
Int(Integer),
Float(f64),
Str(String),
Bin(Bytes),
Array(Vec<Value>),
Map(Vec<(Value, Value)>),
Ext(i8, Bytes),
}Expand description
Any msgpack value.
Maps keep their wire order, so a decoded value re-encodes to the same bytes. Integers keep the signedness of their format for the same reason.
Variants§
Nil
nil
Bool(bool)
A boolean.
Int(Integer)
An integer.
Float(f64)
A float.
Str(String)
A string.
Bin(Bytes)
A binary value.
Array(Vec<Value>)
An array.
Map(Vec<(Value, Value)>)
A map, in wire order.
Ext(i8, Bytes)
An extension value.
Trait Implementations§
impl StructuralPartialEq for Value
Auto Trait Implementations§
impl !Freeze for Value
impl RefUnwindSafe for Value
impl Send for Value
impl Sync for Value
impl Unpin for Value
impl UnsafeUnpin for Value
impl UnwindSafe for Value
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