[][src]Struct misskey_api::model::query::Query

pub struct Query<T>(pub Vec<Vec<T>>);

Implementations

impl<T> Query<T>[src]

pub fn new() -> Self[src]

Creates an empty Query.

pub fn from_vec(vec: Vec<Vec<T>>) -> Self[src]

Creates Query from a vector which represents disjunction of conjunctions of T.

pub fn into_vec(self) -> Vec<Vec<T>>[src]

Turns Query into a vector which represents disjunction of conjunctions of T.

pub fn atom(x: impl Into<T>) -> Self[src]

Creates Query from a single element.

pub fn or(self, rhs: impl Into<Self>) -> Self[src]

Disjunction of two queries.

pub fn and(self, rhs: impl Into<Self>) -> Self where
    T: Clone
[src]

Conjunction of two queries. This operation is expensive for large rhs and implemented just for syntactic brevity of small queries.

For building larger queries, consider using Query::or or Query::from_vec.

Trait Implementations

impl<T: Clone> Clone for Query<T>[src]

impl<T: Debug> Debug for Query<T>[src]

impl<T: Default> Default for Query<T>[src]

impl<'de, T> Deserialize<'de> for Query<T> where
    T: Deserialize<'de>, 
[src]

impl<'_> From<&'_ str> for Query<String>[src]

impl<'_> From<&'_ str> for Query<Tag>[src]

impl<T> From<T> for Query<T>[src]

impl<T> Serialize for Query<T> where
    T: Serialize
[src]

Auto Trait Implementations

impl<T> RefUnwindSafe for Query<T> where
    T: RefUnwindSafe
[src]

impl<T> Send for Query<T> where
    T: Send
[src]

impl<T> Sync for Query<T> where
    T: Sync
[src]

impl<T> Unpin for Query<T> where
    T: Unpin
[src]

impl<T> UnwindSafe for Query<T> where
    T: UnwindSafe
[src]

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> DeserializeOwned for T where
    T: for<'de> Deserialize<'de>, 
[src]

impl<T> From<!> for T[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.