Join Slack
Powered by
Hi, is there a function that waits for multiple ta...
# coroutines
d
dstarcev
08/29/2018, 10:12 AM
Hi, is there a function that waits for multiple tasks to finish and aggregates their exceptions if so?
e
enleur
08/29/2018, 10:14 AM
.awaitAll() to wait all deferreds. but for catching all exceptions there is only proposal
d
dgngulcan
08/29/2018, 12:32 PM
You can use parent jobs and await the parent as in the link here,
https://discuss.kotlinlang.org/t/coroutines-how-to-join-list-of-jobs/6954/4
d
dekans
08/29/2018, 12:51 PM
you can add an exceptionHandler to catch Exception from several coroutines at once:
https://geoffreymetais.github.io/code/coroutines/#coroutine-context
3
Views
Open in Slack
Previous
Next