See: Description
Interface | Description |
---|---|
CancellableContinuation<T> |
Cancellable continuation. It is completed when it is resumed or cancelled.
When
CancellableContinuation.cancel function is explicitly invoked, this continuation immediately resumes with CancellationException or
with the specified cancel cause. |
CompletableDeferred<T> |
A
interface Deferred that can be completed via public functions
CompletableDeferred.complete , CompletableDeferred.completeExceptionally , and cancel. |
CoroutineExceptionHandler |
An optional element on the coroutine context to handle uncaught exceptions.
|
CoroutineScope |
Defines a scope for new coroutines. Every coroutine builder
is an extension on
interface CoroutineScope and inherits its CoroutineScope.getCoroutineContext
to automatically propagate both context elements and cancellation. |
Deferred<T> |
Deferred value is a non-blocking cancellable future.
|
Delay |
This dispatcher feature is implemented by
class CoroutineDispatcher implementations that natively support
scheduled execution of tasks. |
DisposableHandle |
A handle to an allocated object that can be disposed to make it eligible for garbage collection.
|
EventLoop |
Implemented by
class CoroutineDispatcher implementations that have event loop inside and can
be asked to process next event from their event queue. |
Job |
A background job. Conceptually, a job is a cancellable thing with a simple life-cycle that
culminates in its completion. Jobs can be arranged into parent-child hierarchies where cancellation
or completion of parent immediately cancels all its
Job.getChildren . |
ThreadContextElement<S> |
Defines elements in CoroutineContext that are installed into thread context
every time the coroutine with this element in the context is resumed on a thread.
|
Enum | Description |
---|---|
CoroutineStart |
Defines start options for coroutines builders.
It is used in
start parameter of BuildersKt.launch , DeferredKt.async , and other coroutine builder functions. |
Exception | Description |
---|---|
CompletionHandlerException |
This exception gets thrown if an exception is caught while processing CompletionHandler invocation for
interface Job . |
JobCancellationException |
Thrown by cancellable suspending functions if the
interface Job of the coroutine is cancelled or completed
without cause, or with a cause or exception that is not CancellationException
(see Job.getCancellationException ). |
TimeoutCancellationException |
This exception is thrown by
ScheduledKt.withTimeout to indicate timeout. |
General-purpose coroutine builders, contexts, and helper functions.