pub struct MessageResult<M>(pub M::Result)
where
M: Message;Expand description
A helper type which wraps the result of a message handler as a message response.
This is useful when the result type of a message does not implement MessageResponse, and
you can not implement MessageResponse for the type due to the orphan rule. In this case,
you can wrap the result type with this type and use it as the
Handler::Result associate type.
Tuple Fields§
§0: M::ResultTrait Implementations§
Source§impl<M> Debug for MessageResult<M>where
M: Message,
impl<M> Debug for MessageResult<M>where
M: Message,
Auto Trait Implementations§
impl<M> Freeze for MessageResult<M>
impl<M> RefUnwindSafe for MessageResult<M>
impl<M> Send for MessageResult<M>
impl<M> Sync for MessageResult<M>
impl<M> Unpin for MessageResult<M>
impl<M> UnsafeUnpin for MessageResult<M>
impl<M> UnwindSafe for MessageResult<M>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more