rocketraman
07/29/2018, 12:08 PMDeferred<T> from a suspend function explicitly, like @ross_a showed, simply because you don't need to. If you don't want to block at the call-site just use async e.g.
val fooDeferred = async {
aSuspendingFunctionThatGetsAValueFromANetworkAPI()
}
// somewhere down below
fooDeferred.await()