[−][src]Module websocket::async::futures::future
Futures
This module contains the Future
trait and a number of adaptors for this
trait. See the crate docs, and the docs for Future
, for full detail.
Structs
AndThen |
Future for the |
CatchUnwind |
Future for the |
Empty |
A future which is never resolved. |
ExecuteError |
Errors returned from the |
Finished |
A future representing a value that is immediately ready. |
Flatten |
Future for the |
FlattenStream |
Future for the |
FromErr |
Future for the |
Fuse |
A future which "fuses" a future once it's been resolved. |
Inspect |
Do something with the item of a future, passing it on. |
IntoStream |
Future that forwards one element from the underlying future (whether it is success of error) and emits EOF after that. |
Join |
Future for the |
Join3 |
Future for the |
Join4 |
Future for the |
Join5 |
Future for the |
JoinAll |
A future which takes a list of futures and resolves with a vector of the completed values. |
Lazy |
A future which defers creation of the actual future until a callback is scheduled. |
LoopFn |
A future implementing a tail-recursive loop. |
Map |
Future for the |
MapErr |
Future for the |
OrElse |
Future for the |
PollFn |
A future which adapts a function returning |
Select |
Future for the |
Select2 |
Future for the |
SelectAll |
Future for the |
SelectNext |
Future yielded as the second result in a |
SelectOk |
Future for the |
Shared |
A future that is cloneable and can be polled in multiple threads.
Use |
SharedError |
A wrapped error of the original future that is cloneable and implements Deref for ease of use. |
SharedItem |
A wrapped item of the original future that is cloneable and implements Deref for ease of use. |
Then |
Future for the |
Enums
Either |
Combines two different futures yielding the same item and error types into a single type. |
ExecuteErrorKind |
Kinds of errors that can be returned from the |
Loop |
The status of a |
Traits
Executor |
A trait for types which can spawn fresh futures. |
Future |
Trait for types which are a placeholder of a value that may become available at some later point in time. |
FutureFrom |
Asynchronous conversion from a type |
IntoFuture |
Class of types which can be converted into a future. |
Functions
done |
Creates a new "leaf future" which will resolve with the given result. |
empty |
Creates a future which never resolves, representing a computation that never finishes. |
failed |
Creates a "leaf future" from an immediate value of a failed computation. |
join_all |
Creates a future which represents a collection of the results of the futures given. |
lazy |
Creates a new future which will eventually be the same as the one created by the closure provided. |
loop_fn |
Creates a new future implementing a tail-recursive loop. |
ok |
Creates a "leaf future" from an immediate value of a finished and successful computation. |
poll_fn |
Creates a new future wrapping around a function returning |
select_all |
Creates a new future which will select over a list of futures. |
select_ok |
Creates a new future which will select the first successful future over a list of futures. |