Enum entity::Filter [−][src]
pub enum Filter { Id(TypedPredicate<Id>), Type(TypedPredicate<String>), Created(TypedPredicate<u64>), LastUpdated(TypedPredicate<u64>), Field(String, Predicate), Edge(String, Box<Filter>), IntoEdge(String), }
Represents some filter to apply against an ent when searching through a database
Variants
Id(TypedPredicate<Id>)
Filters by the ent’s id
Type(TypedPredicate<String>)
Filters by the ent’s type
Created(TypedPredicate<u64>)
Filters by the ent’s creation timestamp
LastUpdated(TypedPredicate<u64>)
Filters by the ent’s last updated timestamp
Filters by an ent’s field
Filters by an ent connected by an edge; not the same as
Filter::IntoEdge
, which converts an ent to its edge’s ents
IntoEdge(String)
(Special case) Filters by converting an ent into the ents on its edge
Implementations
impl Filter
[src]
pub fn where_id<P: Into<TypedPredicate<Id>>>(p: P) -> Self
[src]
pub fn where_type<P: Into<TypedPredicate<String>>>(p: P) -> Self
[src]
pub fn where_created<P: Into<TypedPredicate<u64>>>(p: P) -> Self
[src]
pub fn where_last_updated<P: Into<TypedPredicate<u64>>>(p: P) -> Self
[src]
pub fn where_field<S: Into<String>, P: Into<Predicate>>(name: S, p: P) -> Self
[src]
pub fn where_edge<S: Into<String>, F: Into<Filter>>(name: S, filter: F) -> Self
[src]
pub fn where_into_edge<S: Into<String>>(name: S) -> Self
[src]
Trait Implementations
impl Clone for Filter
[src]
impl Debug for Filter
[src]
impl Extend<Filter> for Query
[src]
fn extend<T: IntoIterator<Item = Filter>>(&mut self, iter: T)
[src]
Extends the query’s filters with the contents of the iterator
pub fn extend_one(&mut self, item: A)
[src]
pub fn extend_reserve(&mut self, additional: usize)
[src]
Auto Trait Implementations
impl !RefUnwindSafe for Filter
impl !Send for Filter
impl !Sync for Filter
impl Unpin for Filter
impl !UnwindSafe for Filter
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> DynClone for T where
T: Clone,
[src]
T: Clone,
pub fn __clone_box(&self, Private) -> *mut ()
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,