pub enum VirtualFilter {
Show 14 variants
Eq(String, SochValue),
Ne(String, SochValue),
Lt(String, SochValue),
Le(String, SochValue),
Gt(String, SochValue),
Ge(String, SochValue),
Like(String, String),
In(String, Vec<SochValue>),
Between(String, SochValue, SochValue),
IsNull(String),
IsNotNull(String),
And(Vec<VirtualFilter>),
Or(Vec<VirtualFilter>),
Not(Box<VirtualFilter>),
}Expand description
Filter for virtual table scans
Variants§
Eq(String, SochValue)
Equality: column = value
Ne(String, SochValue)
Not equal: column != value
Lt(String, SochValue)
Less than: column < value
Le(String, SochValue)
Less than or equal: column <= value
Gt(String, SochValue)
Greater than: column > value
Ge(String, SochValue)
Greater than or equal: column >= value
Like(String, String)
Like pattern: column LIKE pattern
In(String, Vec<SochValue>)
In set: column IN (values)
Between(String, SochValue, SochValue)
Between: column BETWEEN low AND high
IsNull(String)
Is null: column IS NULL
IsNotNull(String)
Is not null: column IS NOT NULL
And(Vec<VirtualFilter>)
AND of filters
Or(Vec<VirtualFilter>)
OR of filters
Not(Box<VirtualFilter>)
NOT of filter
Implementations§
Source§impl VirtualFilter
impl VirtualFilter
Sourcepub fn from_where_clause(where_clause: &WhereClause) -> Self
pub fn from_where_clause(where_clause: &WhereClause) -> Self
Convert from WHERE clause
Sourcepub fn matches(&self, row: &VirtualRow, schema: &VirtualTableSchema) -> bool
pub fn matches(&self, row: &VirtualRow, schema: &VirtualTableSchema) -> bool
Evaluate filter against a row
Trait Implementations§
Source§impl Clone for VirtualFilter
impl Clone for VirtualFilter
Source§fn clone(&self) -> VirtualFilter
fn clone(&self) -> VirtualFilter
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for VirtualFilter
impl RefUnwindSafe for VirtualFilter
impl Send for VirtualFilter
impl Sync for VirtualFilter
impl Unpin for VirtualFilter
impl UnsafeUnpin for VirtualFilter
impl UnwindSafe for VirtualFilter
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> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
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