bookmate game
en

Mark Murphy

Audiolivros

Citações

b4777467766fez uma citaçãohá 2 anos
So, for example, a repository could wrap its Room DAO write calls in a NonCancellable coroutine:
b4777467766fez uma citaçãohá 2 anos
The downside is that the coroutine cannot be canceled at all, and the code in that coroutine might assume that it can be cancelled normally.
b4777467766fez uma citaçãohá 2 anos
Another approach is to switch to a different CoroutineScope, one that will not be canceled by the user navigating away from our UI. For example, you could use GlobalScope… but we do not have a lot of control over the behavior of GlobalScope.

But, we can create our own CoroutineScope easily enough
fb2epub
Arraste e solte seus arquivos (não mais do que 5 por vez)