[][src]Struct futures_channel::oneshot::Receiver

#[must_use = "futures do nothing unless polled"]
pub struct Receiver<T> { /* fields omitted */ }

A future for a value that will be provided by another asynchronous task.

This is created by the channel function.

Methods

impl<T> Receiver<T>
[src]

Gracefully close this receiver, preventing any subsequent attempts to send to it.

Any send operation which happens after this method returns is guaranteed to fail. After calling this method, you can use Receiver::poll to determine whether a message had previously been sent.

Attempts to receive a message outside of the context of a task.

Does not schedule a task wakeup or have any other side effects.

A return value of None must be considered immediately stale (out of date) unless close has been called first.

Returns an error if the sender was dropped.

Trait Implementations

impl<T> Drop for Receiver<T>
[src]

impl<T: Debug> Debug for Receiver<T>
[src]

impl<T> Unpin for Receiver<T>
[src]

impl<T> Future for Receiver<T>
[src]

🔬 This is a nightly-only experimental API. (futures_api)

futures in libcore are unstable

The result of the Future.

Auto Trait Implementations

impl<T> Send for Receiver<T> where
    T: Send

impl<T> Sync for Receiver<T> where
    T: Send

Blanket Implementations

impl<T> From for T
[src]

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

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

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

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

impl<T> Any for T where
    T: 'static + ?Sized
[src]

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

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

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

impl<F, T, E> TryFuture for F where
    F: Future<Output = Result<T, E>>, 
[src]

The type of successful values yielded by this future

The type of failures yielded by this future