DispatcherWithShutdown
class DispatcherWithShutdown(delegate: CoroutineDispatcher) : CoroutineDispatcher
Content copied to clipboard
Specialized dispatcher useful for graceful shutdown
Constructors
Functions
Link copied to clipboard
Complete shutdown. Any further attempts to dispatch anything will fail with RejectedExecutionException
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
open operator override fun <E : CoroutineContext.Element> get(key: CoroutineContext.Key<E>): E?
Content copied to clipboard
Link copied to clipboard
open override fun <T> interceptContinuation(continuation: Continuation<T>): Continuation<T>
Content copied to clipboard
Link copied to clipboard
Link copied to clipboard
open override fun minusKey(key: CoroutineContext.Key<*>): CoroutineContext
Content copied to clipboard
Link copied to clipboard
Link copied to clipboard
Prepare for shutdown so we will not dispatch on delegate anymore. It is still possible to dispatch coroutines.
Link copied to clipboard
open override fun releaseInterceptedContinuation(continuation: Continuation<*>)
Content copied to clipboard