pub enum WhereExpr {
And(Box<WhereExpr>, Box<WhereExpr>),
Or(Box<WhereExpr>, Box<WhereExpr>),
Condition(Condition),
NotExists(MatchPattern),
True,
}Expand description
A WHERE expression tree that preserves AND/OR grouping.
Variants§
And(Box<WhereExpr>, Box<WhereExpr>)
AND of two sub-expressions.
Or(Box<WhereExpr>, Box<WhereExpr>)
OR of two sub-expressions.
Condition(Condition)
A single scalar condition.
NotExists(MatchPattern)
Absence of one fixed canonical path correlated to outer node bindings. Additional names are local to this block, not outer scalar conditions.
True
Always-true — used when there is no WHERE clause.
Implementations§
Source§impl WhereExpr
impl WhereExpr
Sourcepub fn conditions(&self) -> impl Iterator<Item = &Condition>
pub fn conditions(&self) -> impl Iterator<Item = &Condition>
Iterate outer scalar conditions depth-first, skipping scoped absence paths.
Sourcepub fn for_each_condition_mut(&mut self, f: &mut impl FnMut(&mut Condition))
pub fn for_each_condition_mut(&mut self, f: &mut impl FnMut(&mut Condition))
Apply f to each outer scalar condition, skipping scoped absence paths.
Trait Implementations§
Auto Trait Implementations§
impl Forget for WhereExpr
impl Freeze for WhereExprwhere
*const WhereExpr is !null: Freeze,
PhantomData<WhereExpr>: Freeze,
*const u8 is !null: Freeze,
PhantomData<u8>: Freeze,
PhantomData<String>: Freeze,
PhantomData<ConditionValue>: Freeze,
PhantomData<PatternElement>: Freeze,
impl Move for WhereExpr
impl RefUnwindSafe for WhereExpr
impl Send for WhereExpr
impl Sync for WhereExpr
impl Unpin for WhereExpr
impl UnsafeUnpin for WhereExprwhere
*const WhereExpr is !null: UnsafeUnpin,
PhantomData<WhereExpr>: UnsafeUnpin,
*const u8 is !null: UnsafeUnpin,
PhantomData<u8>: UnsafeUnpin,
PhantomData<String>: UnsafeUnpin,
PhantomData<ConditionValue>: UnsafeUnpin,
PhantomData<PatternElement>: UnsafeUnpin,
impl UnwindSafe for WhereExprwhere
BoxRaw<WhereExpr>: UnwindSafe,
RawVecInner: UnwindSafe,
HashMap<String, ConditionValue>: UnwindSafe,
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