CoroutineScope

interface CoroutineScope (source)

Receiver interface for generic coroutine builders, so that the code inside coroutine has a convenient access to its coroutineContext and its cancellation status via isActive.

Properties

coroutineContext

open val coroutineContext: CoroutineContext

Returns the context of this coroutine.

isActive

abstract val isActive: Boolean

Returns true when this coroutine is still active (has not completed and was not cancelled yet).

Inheritors

AbstractCoroutine

abstract class AbstractCoroutine<in T> : 
    JobSupport,
    Job,
    Continuation<T>,
    CoroutineScope

Abstract base class for implementation of coroutines in coroutine builders.

ActorScope

interface ActorScope<E> : CoroutineScope, ReceiveChannel<E>

Scope for actor coroutine builder.

ProducerScope

interface ProducerScope<in E> : 
    CoroutineScope,
    SendChannel<E>

Scope for produce coroutine builder.