pub enum FilterExpression {
MatchAll,
Raw(String),
Tag {
field: String,
values: Vec<String>,
},
TextExact {
field: String,
value: String,
},
TextLike {
field: String,
value: String,
},
NumericRange {
field: String,
min: String,
max: String,
},
GeoRadius {
field: String,
longitude: f64,
latitude: f64,
radius: f64,
unit: String,
},
TimestampRange {
field: String,
min: String,
max: String,
},
And(Box<FilterExpression>, Box<FilterExpression>),
Or(Box<FilterExpression>, Box<FilterExpression>),
Not(Box<FilterExpression>),
IsMissing {
field: String,
},
}Expand description
Filter expression tree.
Variants§
MatchAll
Wildcard that matches everything.
Raw(String)
Raw Redis Search filter expression supplied verbatim.
Tag
Tag equality or membership expression.
TextExact
Text equality expression.
TextLike
Text wildcard/pattern expression.
NumericRange
Numeric equality/range expression.
GeoRadius
Geo radius expression.
Fields
TimestampRange
Timestamp equality/range expression.
And(Box<FilterExpression>, Box<FilterExpression>)
Logical AND.
Or(Box<FilterExpression>, Box<FilterExpression>)
Logical OR.
Not(Box<FilterExpression>)
Logical NOT.
IsMissing
IsMissing predicate – matches documents where a field is absent.
Implementations§
Trait Implementations§
Source§impl BitAnd for FilterExpression
impl BitAnd for FilterExpression
Source§impl BitOr for FilterExpression
impl BitOr for FilterExpression
Source§impl Clone for FilterExpression
impl Clone for FilterExpression
Source§fn clone(&self) -> FilterExpression
fn clone(&self) -> FilterExpression
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 moreSource§impl Debug for FilterExpression
impl Debug for FilterExpression
Source§impl Display for FilterExpression
impl Display for FilterExpression
Source§impl From<&str> for FilterExpression
impl From<&str> for FilterExpression
Source§impl From<String> for FilterExpression
impl From<String> for FilterExpression
Auto Trait Implementations§
impl Freeze for FilterExpression
impl RefUnwindSafe for FilterExpression
impl Send for FilterExpression
impl Sync for FilterExpression
impl Unpin for FilterExpression
impl UnsafeUnpin for FilterExpression
impl UnwindSafe for FilterExpression
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 moreCreates a shared type from an unshared type.
Source§impl<T> Pointable for T
impl<T> Pointable for T
Source§impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> PolicyExt for Twhere
T: ?Sized,
Source§impl<T> ToCompactString for Twhere
T: Display,
impl<T> ToCompactString for Twhere
T: Display,
Source§fn try_to_compact_string(&self) -> Result<CompactString, ToCompactStringError>
fn try_to_compact_string(&self) -> Result<CompactString, ToCompactStringError>
Fallible version of
ToCompactString::to_compact_string() Read moreSource§fn to_compact_string(&self) -> CompactString
fn to_compact_string(&self) -> CompactString
Converts the given value to a
CompactString. Read moreSource§impl<T> ToStringFallible for Twhere
T: Display,
impl<T> ToStringFallible for Twhere
T: Display,
Source§fn try_to_string(&self) -> Result<String, TryReserveError>
fn try_to_string(&self) -> Result<String, TryReserveError>
ToString::to_string, but without panic on OOM.