Struct actix::MessageResult [−][src]
Expand description
A helper type that implements the MessageResponse
trait.
Examples
use actix::prelude::*; #[derive(Message)] #[rtype(result = "Response")] struct Msg; struct Response; struct MyActor; impl Actor for MyActor { type Context = Context<Self>; } impl Handler<Msg> for MyActor { type Result = MessageResult<Msg>; fn handle(&mut self, _: Msg, _: &mut Context<Self>) -> Self::Result { MessageResult(Response {}) } }
Trait Implementations
Auto Trait Implementations
impl<M> RefUnwindSafe for MessageResult<M> where
<M as Message>::Result: RefUnwindSafe,
impl<M> Send for MessageResult<M> where
<M as Message>::Result: Send,
impl<M> Sync for MessageResult<M> where
<M as Message>::Result: Sync,
impl<M> Unpin for MessageResult<M> where
<M as Message>::Result: Unpin,
impl<M> UnwindSafe for MessageResult<M> where
<M as Message>::Result: UnwindSafe,