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]
pub fn get_ref(&self) -> &T
[src]
Gets a reference to the underlying future in this timeout.
Panics
This function panics if the underlying future has already been consumed.
pub fn get_mut(&mut self) -> &mut T
[src]
Gets a mutable reference to the underlying future in this timeout.
Panics
This function panics if the underlying future has already been consumed.
pub fn into_inner(self) -> T
[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]
fn fmt(&self, __arg_0: &mut Formatter) -> Result
[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]
F: Future<Error = E>,
E: From<TimeoutError<F>>,