pub enum PortableComputedExpr {
Show 24 variants
FieldRef {
path: String,
},
UnwrapOr {
expr: Box<Self>,
default: Value,
},
Binary {
op: PortableBinaryOp,
left: Box<Self>,
right: Box<Self>,
},
Cast {
expr: Box<Self>,
to_type: String,
},
MethodCall {
expr: Box<Self>,
method: String,
args: Vec<Self>,
},
ResolverComputed {
resolver: String,
method: String,
args: Vec<Self>,
},
Literal {
value: Value,
},
Paren {
expr: Box<Self>,
},
Var {
name: String,
},
Let {
name: String,
value: Box<Self>,
body: Box<Self>,
},
If {
condition: Box<Self>,
then_branch: Box<Self>,
else_branch: Box<Self>,
},
None,
Some {
value: Box<Self>,
},
Slice {
expr: Box<Self>,
start: usize,
end: usize,
},
Index {
expr: Box<Self>,
index: usize,
},
U64FromLeBytes {
bytes: Box<Self>,
},
U64FromBeBytes {
bytes: Box<Self>,
},
ByteArray {
bytes: Vec<u8>,
},
Closure {
param: String,
body: Box<Self>,
},
Unary {
op: PortableUnaryOp,
expr: Box<Self>,
},
JsonToBytes {
expr: Box<Self>,
},
ContextSlot,
ContextTimestamp,
Keccak256 {
expr: Box<Self>,
},
}Variants§
FieldRef
UnwrapOr
Binary
Cast
MethodCall
ResolverComputed
Literal
Paren
Var
Let
If
None
Some
Slice
Index
U64FromLeBytes
U64FromBeBytes
ByteArray
Closure
Unary
JsonToBytes
ContextSlot
ContextTimestamp
Keccak256
Trait Implementations§
Source§impl Clone for PortableComputedExpr
impl Clone for PortableComputedExpr
Source§fn clone(&self) -> PortableComputedExpr
fn clone(&self) -> PortableComputedExpr
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · 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 PortableComputedExpr
impl Debug for PortableComputedExpr
Source§impl<'de> Deserialize<'de> for PortableComputedExpr
impl<'de> Deserialize<'de> for PortableComputedExpr
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialEq for PortableComputedExpr
impl PartialEq for PortableComputedExpr
Source§impl Serialize for PortableComputedExpr
impl Serialize for PortableComputedExpr
impl StructuralPartialEq for PortableComputedExpr
Auto Trait Implementations§
impl Freeze for PortableComputedExpr
impl RefUnwindSafe for PortableComputedExpr
impl Send for PortableComputedExpr
impl Sync for PortableComputedExpr
impl Unpin for PortableComputedExpr
impl UnsafeUnpin for PortableComputedExpr
impl UnwindSafe for PortableComputedExpr
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