pub struct ChannelSource<T> { /* private fields */ }Available on crate feature
std only.Expand description
Source adapter over an std::sync::mpsc::Receiver.
pull returns Ok(None) when the channel is empty AND all senders
have been dropped.
Implementations§
Trait Implementations§
Source§impl<T> Source for ChannelSource<T>where
T: 'static,
impl<T> Source for ChannelSource<T>where
T: 'static,
Source§type Error = Infallible
type Error = Infallible
Error type the source can return.
Auto Trait Implementations§
impl<T> Freeze for ChannelSource<T>
impl<T> RefUnwindSafe for ChannelSource<T>
impl<T> Send for ChannelSource<T>where
T: Send,
impl<T> !Sync for ChannelSource<T>
impl<T> Unpin for ChannelSource<T>
impl<T> UnsafeUnpin for ChannelSource<T>
impl<T> UnwindSafe for ChannelSource<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