pub trait IntoAsyncSender<M, R> {
    // Required methods
    fn into_async_sender(self) -> AsyncSender<M, R>;
    fn as_async_sender(self: &Arc<Self>) -> AsyncSender<M, R>;
}
Expand description

Extension functions to wrap a CanSendAsync as an AsyncSender.

Required Methods§

source

fn into_async_sender(self) -> AsyncSender<M, R>

This allows conversion of an owned CanSendAsync into an AsyncSender.

source

fn as_async_sender(self: &Arc<Self>) -> AsyncSender<M, R>

This allows conversion of a reference-counted CanSendAsync into an AsyncSender.

Implementors§

source§

impl<M, R, T: CanSendAsync<M, R>> IntoAsyncSender<M, R> for T