[−][src]Enum avocado::dsl::filter::Filter
A query/filter condition.
Variants
Value(Bson)
Matches if the field has the given value.
Doc(FilterDoc)
A sub-query of multiple path => filter specifiers.
Array(Vec<Filter>)
A sub-query of multiple filters.
Eq(Bson)
Matches if the field is equal to the given value.
Ne(Bson)
Matches if the field is not equal to the given value.
Gt(Bson)
Matches if the field is greater than the given value.
Lt(Bson)
Matches if the field is less than the given value.
Gte(Bson)
Matches if the field is greater than or equal to the given value.
Lte(Bson)
Matches if the field is less than or equal to the given value.
In(Vec<Bson>)
Matches if the value of field is any of the specified values.
Nin(Vec<Bson>)
Matches if the value of field is none of the specified values.
Not(Box<Filter>)
Matches if the field does not satisfy the specified subquery.
Exists(bool)
If the argument is true
, matches if the field exists in the enclosing
document. If it is false
, then matches if the field does not exist.
Type(BsonType)
Matches if the type of the field is any of the specified types.
JsonSchema(Document)
Matches if the value of the field satisfies the given JSON schema.
Regex(Cow<'static, str>, RegexOpts)
Matches if the field is a string satisfying the given regular expression.
All(Vec<Bson>)
Matches if the field is an array containing all the specified values.
ElemMatch(FilterDoc)
Matches if the field is an array containing at least one element that matches all of the specified subqueries.
Size(usize)
Matches if the field is an array whose length is the given value.
Trait Implementations
impl PartialEq<Filter> for Filter
[src]
impl PartialEq<Filter> for Filter
fn eq(&self, other: &Filter) -> bool
[src]
fn eq(&self, other: &Filter) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &Filter) -> bool
[src]
fn ne(&self, other: &Filter) -> bool
This method tests for !=
.
impl<T: Into<Bson>> From<T> for Filter
[src]
impl<T: Into<Bson>> From<T> for Filter
Filter::from(some_bson_value)
results in Filter::Value(some_bson_value)
.
impl From<Document<Filter>> for Filter
[src]
impl From<Document<Filter>> for Filter
Filter::from(FilterDoc)
yields a Filter::Doc(...)
.
impl Clone for Filter
[src]
impl Clone for Filter
fn clone(&self) -> Filter
[src]
fn clone(&self) -> Filter
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
impl Debug for Filter
[src]
impl Debug for Filter
fn fmt(&self, f: &mut Formatter) -> Result
[src]
fn fmt(&self, f: &mut Formatter) -> Result
Formats the value using the given formatter. Read more
impl Serialize for Filter
[src]
impl Serialize for Filter
Auto Trait Implementations
Blanket Implementations
impl<T, U> Into for T where
U: From<T>,
[src]
impl<T, U> Into for T where
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
impl<T> ToOwned for T where
T: Clone,
type Owned = T
fn to_owned(&self) -> T
[src]
fn to_owned(&self) -> T
Creates owned data from borrowed data, usually by cloning. Read more
fn clone_into(&self, target: &mut T)
[src]
fn clone_into(&self, target: &mut T)
🔬 This is a nightly-only experimental API. (toowned_clone_into
)
recently added
Uses borrowed data to replace owned data, usually by cloning. Read more
impl<T> From for T
[src]
impl<T> From for T
impl<T, U> TryFrom for T where
T: From<U>,
[src]
impl<T, U> TryFrom for T where
T: From<U>,
type Error = !
try_from
)The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
try_from
)Performs the conversion.
impl<T> Borrow for T where
T: ?Sized,
[src]
impl<T> Borrow for T where
T: ?Sized,
impl<T> BorrowMut for T where
T: ?Sized,
[src]
impl<T> BorrowMut for T where
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
impl<T, U> TryInto for T where
U: TryFrom<T>,
[src]
impl<T, U> TryInto for T where
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
try_from
)The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
try_from
)Performs the conversion.
impl<T> Any for T where
T: 'static + ?Sized,
[src]
impl<T> Any for T where
T: 'static + ?Sized,
fn get_type_id(&self) -> TypeId
[src]
fn get_type_id(&self) -> TypeId
🔬 This is a nightly-only experimental API. (get_type_id
)
this method will likely be replaced by an associated static
Gets the TypeId
of self
. Read more
impl<T, U> TryInto for T where
U: TryFrom<T>,
impl<T, U> TryInto for T where
U: TryFrom<T>,
impl<T> Same for T
impl<T> Same for T
type Output = T
Should always be Self