Created
January 11, 2020 23:57
-
-
Save RBusarow/07f33a9e1528671d4749169a8f15f3bd to your computer and use it in GitHub Desktop.
more succinct version of the Dispatchers object from kotlinx.coroutines
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
object Dispatchers { | |
val Default: CoroutineDispatcher = createDefaultDispatcher() | |
val Main: MainCoroutineDispatcher get() = MainDispatcherLoader.dispatcher | |
val Unconfined: CoroutineDispatcher = kotlinx.coroutines.Unconfined | |
val IO: CoroutineDispatcher = DefaultScheduler.IO | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment