[][src]Struct async_graphql::Request

pub struct Request { /* fields omitted */ }

GraphQL query request

Implementations

impl Request[src]

pub fn new(query: impl Into<String>) -> Self[src]

Create a request object with query source.

pub fn operation_name<T: Into<String>>(self, name: T) -> Self[src]

Specify the operation name.

pub fn variables(self, variables: Variables) -> Self[src]

Specify the variables.

pub fn data<D: Any + Send + Sync>(self, data: D) -> Self[src]

Add a context data that can be accessed in the Context, you access it with Context::data.

This data is only valid for this query

pub fn set_upload(
    &mut self,
    var_path: &str,
    filename: String,
    content_type: Option<String>,
    content: File
)
[src]

Set uploaded file path

Trait Implementations

impl From<GQLRequest> for Request[src]

impl<T: Into<String>> From<T> for Request[src]

Auto Trait Implementations

impl !RefUnwindSafe for Request

impl Send for Request

impl Sync for Request

impl Unpin for Request

impl !UnwindSafe for Request

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> From<T> for T[src]

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

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.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,