Enum cql3_parser::common::Operand
source · [−]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
sourceimpl From<&BigDecimal> for Operand
impl From<&BigDecimal> for Operand
sourcefn from(b: &BigDecimal) -> Self
fn from(b: &BigDecimal) -> Self
Converts to this type from the input type.
sourceimpl From<&str> for Operand
impl From<&str> for Operand
this is NOT the same as Operand::Const(string) This conversion encloses the value in
single quotes.
sourceimpl Ord for Operand
impl Ord for Operand
1.21.0 · sourcefn max(self, other: Self) -> Self
fn max(self, other: Self) -> Self
Compares and returns the maximum of two values. Read more
1.21.0 · sourcefn min(self, other: Self) -> Self
fn min(self, other: Self) -> Self
Compares and returns the minimum of two values. Read more
1.50.0 · sourcefn clamp(self, min: Self, max: Self) -> Selfwhere
Self: PartialOrd<Self>,
fn clamp(self, min: Self, max: Self) -> Selfwhere
Self: PartialOrd<Self>,
Restrict a value to a certain interval. Read more
sourceimpl PartialOrd<Operand> for Operand
impl PartialOrd<Operand> for Operand
sourcefn partial_cmp(&self, other: &Operand) -> Option<Ordering>
fn partial_cmp(&self, other: &Operand) -> Option<Ordering>
1.0.0 · sourcefn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self and other) and is used by the <=
operator. Read moreimpl Eq for Operand
impl StructuralEq for Operand
impl StructuralPartialEq for Operand
Auto Trait Implementations
impl RefUnwindSafe for Operand
impl Send for Operand
impl Sync for Operand
impl Unpin for Operand
impl UnwindSafe for Operand
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more