Trait slacktor::actor::MessageSender

source ·
pub trait MessageSender<M: Message> {
    // Required method
    fn send(&self, message: M) -> M::Result;
}
Expand description

§MessageSender

Implemented by ActorHandles. Allows the actual type of the actor to be abstracted away, leaving only the type of message that can be sent.

Required Methods§

source

fn send(&self, message: M) -> M::Result

Send a message to the actor and wait for a response

Implementors§