[−][src]Struct async_graphql::Schema 
GraphQL schema
Methods
impl<Query: ObjectType, Mutation: ObjectType, Subscription: SubscriptionType> Schema<Query, Mutation, Subscription>[src]
pub fn new(query: Query, mutation: Mutation, subscription: Subscription) -> Self[src]
Create a schema
The root object for the query and Mutation needs to be specified.
If there is no mutation, you can use EmptyMutation.
If there is no subscription, you can use EmptySubscription.
pub fn data<D: Any + Send + Sync>(self, data: D) -> Self[src]
Add a global data that can be accessed in the Context.
pub fn query<'a>(&'a self, source: &'a str) -> QueryBuilder<'a, Query, Mutation>[src]
Start a query and return QueryBuilder.
pub fn subscribe<'a>(
    &'a self, 
    source: &'a str
) -> SubscribeBuilder<'a, Subscription>[src]
&'a self,
source: &'a str
) -> SubscribeBuilder<'a, Subscription>
Start a subscribe and return SubscribeBuilder.
Auto Trait Implementations
impl<Query, Mutation, Subscription> !RefUnwindSafe for Schema<Query, Mutation, Subscription>
impl<Query, Mutation, Subscription> Send for Schema<Query, Mutation, Subscription> where
    Mutation: Send,
    Query: Send,
    Subscription: Send, 
Mutation: Send,
Query: Send,
Subscription: Send,
impl<Query, Mutation, Subscription> Sync for Schema<Query, Mutation, Subscription> where
    Mutation: Sync,
    Query: Sync,
    Subscription: Sync, 
Mutation: Sync,
Query: Sync,
Subscription: Sync,
impl<Query, Mutation, Subscription> Unpin for Schema<Query, Mutation, Subscription> where
    Mutation: Unpin,
    Query: Unpin,
    Subscription: Unpin, 
Mutation: Unpin,
Query: Unpin,
Subscription: Unpin,
impl<Query, Mutation, Subscription> !UnwindSafe for Schema<Query, Mutation, Subscription>
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,
fn borrow_mut(&mut self) -> &mut T[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, 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.
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>,