[−][src]Struct async_graphql_actix_web::WSSubscription
Actor for subscription via websocket
Methods
impl<Query, Mutation, Subscription> WSSubscription<Query, Mutation, Subscription> where
Query: ObjectType + Send + Sync + 'static,
Mutation: ObjectType + Send + Sync + 'static,
Subscription: SubscriptionType + Send + Sync + 'static,
[src]
Query: ObjectType + Send + Sync + 'static,
Mutation: ObjectType + Send + Sync + 'static,
Subscription: SubscriptionType + Send + Sync + 'static,
pub fn new(schema: &Schema<Query, Mutation, Subscription>) -> Self
[src]
Create an actor for subscription connection via websocket.
Trait Implementations
impl<Query, Mutation, Subscription> Actor for WSSubscription<Query, Mutation, Subscription> where
Query: ObjectType + Sync + Send + 'static,
Mutation: ObjectType + Sync + Send + 'static,
Subscription: SubscriptionType + Send + Sync + 'static,
[src]
Query: ObjectType + Sync + Send + 'static,
Mutation: ObjectType + Sync + Send + 'static,
Subscription: SubscriptionType + Send + Sync + 'static,
type Context = WebsocketContext<Self>
Actor execution context type
fn started(&mut self, ctx: &mut Self::Context)
[src]
fn stopping(&mut self, ctx: &mut Self::Context) -> Running
[src]
fn stopped(&mut self, ctx: &mut Self::Context)
[src]
fn start(self) -> Addr<Self> where
Self: Actor<Context = Context<Self>>,
[src]
Self: Actor<Context = Context<Self>>,
fn start_default() -> Addr<Self> where
Self: Actor<Context = Context<Self>> + Default,
[src]
Self: Actor<Context = Context<Self>> + Default,
fn start_in_arbiter<F>(arb: &Arbiter, f: F) -> Addr<Self> where
F: FnOnce(&mut Context<Self>) -> Self + Send + 'static,
Self: Actor<Context = Context<Self>>,
[src]
F: FnOnce(&mut Context<Self>) -> Self + Send + 'static,
Self: Actor<Context = Context<Self>>,
fn create<F>(f: F) -> Addr<Self> where
F: FnOnce(&mut Context<Self>) -> Self,
Self: Actor<Context = Context<Self>>,
[src]
F: FnOnce(&mut Context<Self>) -> Self,
Self: Actor<Context = Context<Self>>,
impl<Query, Mutation, Subscription> StreamHandler<Bytes> for WSSubscription<Query, Mutation, Subscription> where
Query: ObjectType + Send + Sync + 'static,
Mutation: ObjectType + Send + Sync + 'static,
Subscription: SubscriptionType + Send + Sync + 'static,
[src]
Query: ObjectType + Send + Sync + 'static,
Mutation: ObjectType + Send + Sync + 'static,
Subscription: SubscriptionType + Send + Sync + 'static,
fn handle(&mut self, data: Bytes, ctx: &mut Self::Context)
[src]
fn started(&mut self, ctx: &mut Self::Context)
[src]
fn finished(&mut self, ctx: &mut Self::Context)
[src]
fn add_stream<S>(fut: S, ctx: &mut Self::Context) -> SpawnHandle where
I: 'static,
S: Stream<Item = I> + 'static,
Self::Context: AsyncContext<Self>,
[src]
I: 'static,
S: Stream<Item = I> + 'static,
Self::Context: AsyncContext<Self>,
impl<Query, Mutation, Subscription> StreamHandler<Result<Message, ProtocolError>> for WSSubscription<Query, Mutation, Subscription> where
Query: ObjectType + Sync + Send + 'static,
Mutation: ObjectType + Sync + Send + 'static,
Subscription: SubscriptionType + Send + Sync + 'static,
[src]
Query: ObjectType + Sync + Send + 'static,
Mutation: ObjectType + Sync + Send + 'static,
Subscription: SubscriptionType + Send + Sync + 'static,
fn handle(
&mut self,
msg: Result<Message, ProtocolError>,
ctx: &mut Self::Context
)
[src]
&mut self,
msg: Result<Message, ProtocolError>,
ctx: &mut Self::Context
)
fn started(&mut self, ctx: &mut Self::Context)
[src]
fn finished(&mut self, ctx: &mut Self::Context)
[src]
fn add_stream<S>(fut: S, ctx: &mut Self::Context) -> SpawnHandle where
I: 'static,
S: Stream<Item = I> + 'static,
Self::Context: AsyncContext<Self>,
[src]
I: 'static,
S: Stream<Item = I> + 'static,
Self::Context: AsyncContext<Self>,
Auto Trait Implementations
impl<Query, Mutation, Subscription> !RefUnwindSafe for WSSubscription<Query, Mutation, Subscription>
impl<Query, Mutation, Subscription> Send for WSSubscription<Query, Mutation, Subscription> where
Mutation: Send + Sync,
Query: Send + Sync,
Subscription: Send + Sync,
Mutation: Send + Sync,
Query: Send + Sync,
Subscription: Send + Sync,
impl<Query, Mutation, Subscription> Sync for WSSubscription<Query, Mutation, Subscription> where
Mutation: Send + Sync,
Query: Send + Sync,
Subscription: Send + Sync,
Mutation: Send + Sync,
Query: Send + Sync,
Subscription: Send + Sync,
impl<Query, Mutation, Subscription> Unpin for WSSubscription<Query, Mutation, Subscription>
impl<Query, Mutation, Subscription> !UnwindSafe for WSSubscription<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>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
V: MultiLane<T>,