Enum msgpack_value::Value
source · pub enum Value {
Nil,
Bool(bool),
Int(Int),
F32(f32),
F64(f64),
Str(Str),
Bin(Bin),
Array(Vec<Value>),
Map(Vec<(Value, Value)>),
Ext(Ext),
}
Variants§
Nil
Bool(bool)
Int(Int)
F32(f32)
F64(f64)
Str(Str)
Bin(Bin)
Array(Vec<Value>)
Map(Vec<(Value, Value)>)
Ext(Ext)
Implementations§
source§impl Value
impl Value
pub fn is_nil(&self) -> bool
pub fn is_bool(&self) -> bool
pub fn is_int(&self) -> bool
pub fn is_f32(&self) -> bool
pub fn is_f64(&self) -> bool
pub fn is_str(&self) -> bool
pub fn is_bin(&self) -> bool
pub fn is_array(&self) -> bool
pub fn is_map(&self) -> bool
pub fn is_ext(&self) -> bool
pub fn as_bool(&self) -> Option<bool>
pub fn as_int(&self) -> Option<Int>
pub fn as_f32(&self) -> Option<f32>
pub fn as_f64(&self) -> Option<f64>
pub fn as_str(&self) -> Option<&Str>
pub fn as_str_mut(&mut self) -> Option<&mut Str>
pub fn as_bin(&self) -> Option<&Bin>
pub fn as_bin_mut(&mut self) -> Option<&mut Bin>
pub fn as_array(&self) -> Option<&[Value]>
pub fn as_array_mut(&mut self) -> Option<&mut Vec<Value>>
pub fn as_map(&self) -> Option<&[(Value, Value)]>
pub fn as_map_mut(&mut self) -> Option<&mut Vec<(Value, Value)>>
pub fn as_ext(&self) -> Option<&Ext>
pub fn as_ext_mut(&mut self) -> Option<&mut Ext>
Trait Implementations§
source§impl Arbitrary for Value
impl Arbitrary for Value
§type Parameters = ()
type Parameters = ()
The type of parameters that
arbitrary_with
accepts for configuration
of the generated Strategy
. Parameters must implement Default
.§type Strategy = BoxedStrategy<Value>
type Strategy = BoxedStrategy<Value>
The type of
Strategy
used to generate values of type Self
.