SnapshotMutableState


A mutable value holder where reads to the value property during the execution of a Composable function, the current RecomposeScope will be subscribed to changes of that value. When the value property is written to and changed, a recomposition of any subscribed RecomposeScopes will be scheduled. Writes to it are transacted as part of the Snapshot system.

In general for correctness: Anything that is mutable, that is read during composition or written to during composition, should be a SnapshotMutableState.

Summary

Public properties

SnapshotMutationPolicy<T>

A policy to control how changes are handled in a mutable snapshot.

Cmn

Inherited functions

From androidx.compose.runtime.MutableState
operator T
Cmn
operator (T) -> Unit
Cmn

Inherited properties

From androidx.compose.runtime.MutableState
T
Cmn

Public properties

policy

val policySnapshotMutationPolicy<T>

A policy to control how changes are handled in a mutable snapshot.