pub enum Action<T> {
Reply(T),
FutureReply(Box<dyn Future<Item = T, Error = Never> + Send + 'static>),
NoReply,
FutureNoReply(Box<dyn Future<Item = (), Error = Never> + Send + 'static>),
}
Expand description
Action instructed by an operation of a message handler.
Variants§
Reply(T)
Replies an response to the client immediately.
FutureReply(Box<dyn Future<Item = T, Error = Never> + Send + 'static>)
Replies an response to the client in the future.
NoReply
Does not reply to the client.
FutureNoReply(Box<dyn Future<Item = (), Error = Never> + Send + 'static>)
Does not reply to the client, but does something for handling the incoming message.
Trait Implementations§
Auto Trait Implementations§
impl<T> !RefUnwindSafe for Action<T>
impl<T> Send for Action<T>where
T: Send,
impl<T> !Sync for Action<T>
impl<T> Unpin for Action<T>where
T: Unpin,
impl<T> !UnwindSafe for Action<T>
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