TraceOutcome

How a traced block ended.

Example:

when (finished.outcome) {
TraceOutcome.Completed -> ok()
is TraceOutcome.Threw -> report(finished.outcome.error)
}

Requires opting in to ExperimentalStructuredCoroutines.

Inheritors

Types

Link copied to clipboard

The block returned normally.

Link copied to clipboard
class Threw(val error: Throwable) : TraceOutcome

The block ended by throwing error (including cancellation).