{% setvar book_path %}/reference/androidx/_book.yaml{% endsetvar %} {% include "_shared/_reference-head-tags.html" %}

SnapshotContextElement

@ExperimentalComposeApi
public interface SnapshotContextElement extends CoroutineContext.Element


A CoroutineContext element that enters an associated snapshot whenever a coroutine associated with this context is resumed.

Summary

Nested types

public static class SnapshotContextElement.Key implements CoroutineContext.Key

Inherited methods

From kotlin.coroutines.CoroutineContext
From kotlin.coroutines.CoroutineContext.Element
default @NonNull R
<R extends Object> fold(
    @NonNull R initial,
    @NonNull Function2<@NonNull R, @NonNull CoroutineContext.Element, @NonNull R> operation
)
default E
abstract @NonNull CoroutineContext.Key<@NonNull ?>
default @NonNull CoroutineContext