Trait actix::Handler [] [src]

pub trait Handler<M> where
    Self: Actor,
    M: ResponseType
{ type Result: IntoResponse<Self, M>; fn handle(&mut self, msg: M, ctx: &mut Self::Context) -> Self::Result; }

Message handler

Handler implementation is a general way how to handle incoming messages, streams, futures.

M is a message which can be handled by the actor.

Associated Types

Required Methods

Method is called for every message received by this Actor

Implementors