pub enum FieldOp {
Field(FieldExpr),
Cmp {
op: OpQuery,
lhs: Box<FieldOp>,
rhs: Box<FieldOp>,
},
}Variants§
Implementations§
Source§impl FieldOp
impl FieldOp
pub fn new(op: OpQuery, lhs: Self, rhs: Self) -> Self
pub fn cmp( field: impl Into<FieldName>, op: OpCmp, value: impl Into<AlgebraicValue>, ) -> Self
pub fn names_to_cols(self, head: &Header) -> Result<ColumnOp, RelationError>
Sourcepub fn flatten_ands(self) -> SmallVec<[FieldOp; 1]>
pub fn flatten_ands(self) -> SmallVec<[FieldOp; 1]>
Flattens a nested conjunction of AND expressions.
For example, a = 1 AND b = 2 AND c = 3 becomes [a = 1, b = 2, c = 3].
This helps with splitting the kinds of queries,
that could be answered by a index,
from the ones that need to be executed with a scan.
Trait Implementations§
Source§impl Ord for FieldOp
impl Ord for FieldOp
Source§impl PartialOrd for FieldOp
impl PartialOrd for FieldOp
impl Eq for FieldOp
impl StructuralPartialEq for FieldOp
Auto Trait Implementations§
impl Freeze for FieldOp
impl RefUnwindSafe for FieldOp
impl Send for FieldOp
impl Sync for FieldOp
impl Unpin for FieldOp
impl UnwindSafe for FieldOp
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<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.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