pub enum JsonExpr {
Obj {
values: BTreeMap<String, JsonExpr>,
},
Arr(Vec<JsonExpr>),
Str(String),
Num(f64),
Bool(bool),
Null(()),
}Expand description
An ESExpr representation of a JSON value.
Variants§
Obj
A JSON Object
Arr(Vec<JsonExpr>)
A JSON Array
Str(String)
A JSON String
Num(f64)
A JSON Number
Bool(bool)
A JSON Boolean
Null(())
A JSON Null value
Implementations§
Trait Implementations§
Source§impl<'esexpr_lifetime> ESExprCodec<'esexpr_lifetime> for JsonExpr
impl<'esexpr_lifetime> ESExprCodec<'esexpr_lifetime> for JsonExpr
Source§const TAGS: ESExprTagSet
const TAGS: ESExprTagSet
The tags of the encoded expressions that this type can produce.
Source§fn encode_esexpr(&'esexpr_lifetime self) -> ESExpr<'esexpr_lifetime>
fn encode_esexpr(&'esexpr_lifetime self) -> ESExpr<'esexpr_lifetime>
Encode this value into an expression.
Source§fn decode_esexpr(expr: ESExpr<'esexpr_lifetime>) -> Result<Self, DecodeError>
fn decode_esexpr(expr: ESExpr<'esexpr_lifetime>) -> Result<Self, DecodeError>
Decode an expression into a value. Read more
Source§impl ESExprEncodedEq for JsonExpr
impl ESExprEncodedEq for JsonExpr
Source§fn is_encoded_eq(&self, other: &Self) -> bool
fn is_encoded_eq(&self, other: &Self) -> bool
Determines whether two values are equal when encoded as
ESExpr.impl StructuralPartialEq for JsonExpr
Auto Trait Implementations§
impl Freeze for JsonExpr
impl RefUnwindSafe for JsonExpr
impl Send for JsonExpr
impl Sync for JsonExpr
impl Unpin for JsonExpr
impl UnwindSafe for JsonExpr
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