Expand description
Combinators and utilities for working with Futures, Streams, Sinks,
and the AsyncRead and AsyncWrite traits.
Re-exports§
pub use futures_util::Future;pub use futures_util::FutureExt;pub use futures_util::TryFuture;pub use futures_util::TryFutureExt;pub use futures_util::Stream;pub use futures_util::StreamExt;pub use futures_util::TryStream;pub use futures_util::TryStreamExt;
Macros§
- join
- Polls multiple futures simultaneously, returning a tuple of all results once complete.
- join_
internal - The
join!macro. - pending
- A macro which yields to the event loop once.
- pin_mut
- Pins a value on the stack.
- poll
- A macro which returns the result of polling a future once within the
current
asynccontext. - ready
- Extracts the successful type of
Poll<T>. - select
- Polls multiple futures and streams simultaneously, executing the branch
for the future that finishes first. If multiple futures are ready,
one will be pseudo-randomly selected at runtime. Futures directly
passed to
select!must beUnpinand implementFusedFuture. - select_
biased - Polls multiple futures and streams simultaneously, executing the branch
for the future that finishes first. Unlike
select!, if multiple futures are ready, one will be selected in order of declaration. Futures directly passed toselect_biased!must beUnpinand implementFusedFuture. - select_
biased_ internal - The
select_biased!macro. - select_
internal - The
select!macro. - stream_
select - Combines several streams, all producing the same
Itemtype, into one stream. This is similar toselect_allbut does not require the streams to all be the same type. It also keeps the streams inline, and does not requireBox<dyn Stream>s to be allocated. Streams passed to this macro must beUnpin. - stream_
select_ internal - The
stream_select!macro. - try_
join - Polls multiple futures simultaneously, resolving to a
Resultcontaining either a tuple of the successful outputs or an error. - try_
join_ internal - The
try_join!macro.