Struct actix::prelude::Address
[−]
[src]
pub struct Address<A> where
A: Actor,
A::Context: AsyncContext<A>, { /* fields omitted */ }
Address of the actor
Actor has to run in the same thread as owner of the address.
Methods
impl<A> Address<A> where
A: Actor,
A::Context: AsyncContext<A>,
[src]
A: Actor,
A::Context: AsyncContext<A>,
fn connected(&self) -> bool
[src]
Indicates if address is still connected to the actor.
fn send<M>(&self, msg: M) where
A: Handler<M>,
M: ResponseType + 'static,
[src]
A: Handler<M>,
M: ResponseType + 'static,
Send message M
to actor A
. Communication channel to the actor is
unbuonded.
fn call<B, M>(&self, _: &B, msg: M) -> Request<B, M> where
A: Handler<M>,
B: Actor,
M: ResponseType + 'static,
[src]
A: Handler<M>,
B: Actor,
M: ResponseType + 'static,
Send message to actor A
and asyncronously wait for response.
Communication channel to the actor is unbuonded.
fn call_fut<M>(&self, msg: M) -> Receiver<Result<M::Item, M::Error>> where
A: Handler<M>,
M: ResponseType + 'static,
[src]
A: Handler<M>,
M: ResponseType + 'static,
Send message to the actor A
and asyncronously wait for response.
fn upgrade(&self) -> Receiver<SyncAddress<A>>
[src]
Upgrade address to SyncAddress.
fn subscriber<M>(&self) -> Box<Subscriber<M>> where
A: Handler<M>,
M: ResponseType + 'static,
[src]
A: Handler<M>,
M: ResponseType + 'static,
Get Subscriber
for specific message type
Trait Implementations
impl<A> Clone for Address<A> where
A: Actor,
A::Context: AsyncContext<A>,
[src]
A: Actor,
A::Context: AsyncContext<A>,
fn clone(&self) -> Self
[src]
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Performs copy-assignment from source
. Read more
impl<A, M> Subscriber<M> for Address<A> where
A: Actor + Handler<M>,
A::Context: AsyncContext<A>,
M: ResponseType + 'static,
[src]
A: Actor + Handler<M>,
A::Context: AsyncContext<A>,
M: ResponseType + 'static,
fn send(&self, msg: M) -> Result<(), M>
[src]
Send buffered message
fn subscriber(&self) -> Box<Subscriber<M>>
[src]
Clone subscriber