pub enum Condition {
Equal(Value),
NotEqual(Value),
LessThan(f64),
GreaterThan(f64),
LessThanOrEqual(f64),
GreaterThatOrEqual(f64),
Prefix(Cow<'static, str>),
Range(f64, f64),
Contains(Cow<'static, str>),
NotContains(Cow<'static, str>),
}Expand description
Enum specifying the variants of conditions to be useed when querying (fetching) the items. The type contains factory methods to facilitate the construction of variants. Check deta docs for more information.
Variants§
Equal(Value)
NotEqual(Value)
LessThan(f64)
GreaterThan(f64)
LessThanOrEqual(f64)
GreaterThatOrEqual(f64)
Prefix(Cow<'static, str>)
Range(f64, f64)
Contains(Cow<'static, str>)
NotContains(Cow<'static, str>)
Implementations§
Source§impl Condition
Factory methods.
impl Condition
Factory methods.
pub fn equal<T>(value: T) -> Result<Condition>where
T: Serialize,
pub fn not_equal<T>(value: T) -> Result<Condition>where
T: Serialize,
pub fn less_than<T>(value: T) -> Condition
pub fn greater_than<T>(value: T) -> Condition
pub fn less_than_or_equal<T>(value: T) -> Condition
pub fn greater_than_or_equal<T>(value: T) -> Condition
pub fn prefix<T>(value: T) -> Condition
pub fn range<T>(start: T, end: T) -> Condition
pub fn contains<T>(value: T) -> Condition
pub fn not_contains<T>(value: T) -> Condition
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Condition
impl RefUnwindSafe for Condition
impl Send for Condition
impl Sync for Condition
impl Unpin for Condition
impl UnwindSafe for Condition
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