rkeazor
09/04/2019, 11:41 AMmarstran
09/04/2019, 11:48 AMwithContext
is like doing await
immediately on the Deferred
from async
. Use async
if you want to do something else while waiting for the Deferred
to complete.louiscad
09/04/2019, 12:09 PMasync
block will cancel the parent scope.
withContext
will only throw and will let you catch without an extra scope.rkeazor
09/04/2019, 12:09 PMrkeazor
09/04/2019, 12:09 PMrkeazor
09/04/2019, 12:11 PMrkeazor
09/04/2019, 12:12 PMrkeazor
09/04/2019, 12:12 PMlouiscad
09/04/2019, 1:22 PMwithContext
if I need to change the dispatcher.
The only exception might be using flowOn
to make a flow run on a specific dispatcher.
async
is for parallelization in a coroutine.Dominaezzz
09/04/2019, 3:46 PMlouiscad
09/04/2019, 5:45 PM