Module future

Module future 

Source
Expand description

Common Future types and utilities.

Structs§

Context
The context of an asynchronous task.
MapErr
A TryFuture that modifies the original error.

Enums§

Poll
Indicates whether a value is available or if the current task has been scheduled to receive a wakeup instead.

Traits§

Future
A future represents an asynchronous computation, commonly obtained by use of async.
TryFuture
A Future that returns a result.
TryFutureExt
Extension methods for futures that return a result.

Functions§

catch_unwind
Waits for a future to be ready or panic.
forever
Waits forever.
poll
Polls a future and returns its result if it is ready.
race
Waits for one of two futures to be ready and returns its result.
try_resolve
Polls the future once then drops it, returning the output if the future was ready.

Attribute Macros§

boxed
Modifies an async function to return a Box<dyn Future + Send>.
boxed_local
Modifies an async function to return a Box<dyn Future>.