CoroutineScope

fun CoroutineScope(context: CoroutineContext): CoroutineScope (source)

Creates a CoroutineScope that wraps the given coroutine context.

If the given context does not contain a Job element, then a default Job() is created. This way, cancellation or failure or any child coroutine in this scope cancels all the other children, just like inside coroutineScope block.