Class
Common
@ExperimentalComposeRuntimeApi
public class SnapshotFlowManager
Orchestrates the observation of Snapshot state for snapshotFlows that are collected on the same thread.
Once a SnapshotFlowManager is no longer needed, its dispose method should be called.
It is not safe to share a SnapshotFlowManager instance across two snapshotFlows that collect in parallel on two different threads, but it is not a problem for a thread to run apply observers in parallel with another thread collecting a snapshotFlow.
Functions
public fun dispose()
Disposes of this manager. Disposing of a manager disconnects it from the Snapshot system, rendering it incapable of handling any subscriptions.
If this method is called after this manager has been disposed of, an IllegalStateException will be thrown.