pub enum Operand {
Const(String),
Map(Vec<(String, String)>),
Set(Vec<String>),
List(Vec<String>),
Tuple(Vec<Operand>),
Column(Identifier),
Func(String),
Param(String),
Null,
}
Expand description
An object that can be on either side of an Operator
Variants§
Const(String)
A constant
Map(Vec<(String, String)>)
a map displays as { String:String, String:String, ... }
Set(Vec<String>)
a set of values. Displays as ( String, String, ...)
List(Vec<String>)
a list of values. Displays as [String, String, ...]
Tuple(Vec<Operand>)
a tuple of values. Displays as { Operand, Operand, ... }
Column(Identifier)
A column name
Func(String)
A function call e.g. foo(bar)
Param(String)
A parameter. The string will either be ‘?’ or ‘:name’
Null
the NULL
value.
Implementations§
Trait Implementations§
Source§impl From<&BigDecimal> for Operand
impl From<&BigDecimal> for Operand
Source§fn from(b: &BigDecimal) -> Self
fn from(b: &BigDecimal) -> Self
Converts to this type from the input type.
Source§impl From<&str> for Operand
this is NOT the same as Operand::Const(string)
This conversion encloses the value in
single quotes.
impl From<&str> for Operand
this is NOT the same as Operand::Const(string)
This conversion encloses the value in
single quotes.
Source§impl Ord for Operand
impl Ord for Operand
Source§impl PartialOrd for Operand
impl PartialOrd for Operand
impl Eq for Operand
impl StructuralPartialEq for Operand
Auto Trait Implementations§
impl Freeze for Operand
impl RefUnwindSafe for Operand
impl Send for Operand
impl Sync for Operand
impl Unpin for Operand
impl UnwindSafe for Operand
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more