Function async_ui_web::try_join
source · pub fn try_join<F>(f: F) -> <F as TryJoin>::Futurewhere
F: TryJoin,Expand description
Wait for all futures to complete successfully, or return early on error.
TryJoin takes in many fallible (returns Result) “subfutures” and return
a single Future.
When awaited, the returned Future will drive all of the subfuture until
either all of them return Ok(_) or any of them return Err(_).
Subfutures may be passed in as either
- a tuple of up to 12 Futures, all with the same Error type
(signature:
(F1, F2, ...) -> Result<(F1::Ok, F2::Ok, ...), Error>) - an array of Futures
(signature:
[F; N] -> Result<[F::Ok; N], F::Error>) - a Vec of Futures
(signature:
Vec<F> -> Result<Vec<F::Ok>, F::Error>)