DispatcherModule

@Module
object DispatcherModule

Dagger module that provides coroutine dispatchers for different contexts.

Functions

Link copied to clipboard
@Provides
fun providesDefaultDispatcher(): CoroutineDispatcher

Provides the default coroutine dispatcher, which is used for general-purpose background tasks.

Link copied to clipboard
@Provides
fun providesIoDispatcher(): CoroutineDispatcher

Provides the I/O coroutine dispatcher, which is used for I/O-bound tasks such as disk or network operations.

Link copied to clipboard
@Provides
fun providesMainDispatcher(): CoroutineDispatcher

Provides the main coroutine dispatcher, which is used for executing tasks on the main/UI thread.