await
Awaits for completion of this completable without blocking the thread. Returns Unit
, or throws the corresponding exception if this completable produces an error.
This suspending function is cancellable. If the Job of the invoking coroutine is cancelled while this suspending function is suspended, this function immediately resumes with CancellationException and disposes of its subscription.
Awaits for completion of the single value response without blocking the thread. Returns the resulting value, or throws the corresponding exception if this response produces an error.
This suspending function is cancellable. If the Job of the current coroutine is cancelled while the suspending function is waiting, this function immediately disposes of its subscription and resumes with CancellationException.