Dispatchers
Groups various implementations of CoroutineDispatcher.
Groups various implementations of CoroutineDispatcher.
Properties
The default CoroutineDispatcher that is used by all standard builders like launch, async, etc. if neither a dispatcher nor any other ContinuationInterceptor is specified in their context.
The CoroutineDispatcher that is designed for offloading blocking IO tasks to a shared pool of threads.
The CoroutineDispatcher that is designed for offloading blocking IO tasks to a shared pool of threads. Additional threads in this pool are created on demand. Default IO pool size is 64
; on JVM it can be configured using JVM-specific mechanisms, please refer to Dispatchers.IO
documentation on JVM platform.
A coroutine dispatcher that is confined to the Main thread operating with UI objects. Usually such dispatchers are single-threaded.
A coroutine dispatcher that is not confined to any specific thread. It executes the initial continuation of a coroutine in the current call-frame and lets the coroutine resume in whatever thread that is used by the corresponding suspending function, without mandating any specific threading policy. Nested coroutines launched in this dispatcher form an event-loop to avoid stack overflows.