Struct suzy::watch::WatchedReceiver[][src]

pub struct WatchedReceiver<T> { /* fields omitted */ }

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]

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]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.