Struct suzy::watch::WatchedReceiver [−][src]
The receiver half of a watched channel.
The methods exposed on this type corospond to the non-blocking methods on the std channel Receiver, but they also bind watch closures, so that when new data is sent those closures will be re-run.
Implementations
impl<T> WatchedReceiver<T>
[src]
pub fn recv(&self) -> Result<T, TryRecvError>
[src]
Attempts to return a pending value on this receiver.
This corosponds to the try_recv
method on the std Receiver, but
additionally binds enclosing watch closures, so that they will be
re-run when new data might be available.
pub fn iter(&self) -> TryIter<'_, T>
[src]
Returns an iterator that will attempt to yield all pending values.
This corosponds to the try_iter
method on the std Receiver, but
additionally binds enclosing watch closures, so that they will be
re-run when new data might be available.
Trait Implementations
impl<T> Debug for WatchedReceiver<T> where
T: Debug,
[src]
T: Debug,
Auto Trait Implementations
impl<T> !RefUnwindSafe for WatchedReceiver<T>
impl<T> !Send for WatchedReceiver<T>
impl<T> !Sync for WatchedReceiver<T>
impl<T> Unpin for WatchedReceiver<T>
impl<T> !UnwindSafe for WatchedReceiver<T>
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>,