Struct tokio_timer_futures2::Timeout [] [src]

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

Allows a given Future to execute for a max duration

Methods

impl<T> Timeout<T>
[src]

[src]

Gets a reference to the underlying future in this timeout.

Panics

This function panics if the underlying future has already been consumed.

[src]

Gets a mutable reference to the underlying future in this timeout.

Panics

This function panics if the underlying future has already been consumed.

[src]

Consumes this timeout, returning the underlying future.

Panics

This function panics if the underlying future has already been consumed.

Trait Implementations

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

[src]

Formats the value using the given formatter. Read more

impl<F, E> Future for Timeout<F> where
    F: Future<Error = E>,
    E: From<TimeoutError<F>>, 
[src]

A successful value

An error

[src]

Attempt to resolve the future to a final value, registering the current task for wakeup if the value is not yet available. Read more

Auto Trait Implementations

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

impl<T> Sync for Timeout<T> where
    T: Sync