Struct actix::MessageResult [−][src]
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
impl<A, M> MessageResponse<A, M> for MessageResult<M> where
A: Actor,
M: Message,
[src]
A: Actor,
M: Message,
Auto Trait Implementations
impl<M> RefUnwindSafe for MessageResult<M> where
<M as Message>::Result: RefUnwindSafe,
<M as Message>::Result: RefUnwindSafe,
impl<M> Send for MessageResult<M> where
<M as Message>::Result: Send,
<M as Message>::Result: Send,
impl<M> Sync for MessageResult<M> where
<M as Message>::Result: Sync,
<M as Message>::Result: Sync,
impl<M> Unpin for MessageResult<M> where
<M as Message>::Result: Unpin,
<M as Message>::Result: Unpin,
impl<M> UnwindSafe for MessageResult<M> where
<M as Message>::Result: UnwindSafe,
<M as Message>::Result: UnwindSafe,
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,
pub 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.
pub 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>,