Skip to main content

Module local_state

Module local_state 

Expand description

Small, typed process-local state for retained application views.

Durable/shareable values belong in the app’s Automerge document. This handle is for presentation state that should survive between widget events without becoming part of persistence, collaboration, or undo history.

Structs§

Intents
The queue a view’s controls write what they ask for to, and its app applies in one ordered place after the event: a click, a key and an accessibility action all become the same intent. Clones share the queue.
LatestRequest
UI-thread inbox for worker results where only the newest request may win.
LatestTask
Typed state for restartable background work where only the latest run may publish a result. Starting or cancelling a run invalidates every older TaskCompletion.
LocalState
A cloneable handle to typed, process-local application state.
LocalStateWriter
A background-safe LocalState mutation handle with event-loop wakeup.
RequestCompletion
Single-use worker capability returned by LatestRequest::begin.
TaskCompletion
A single-use capability returned by LatestTask::begin.
WakeHandle
Captures one scope, or remains detached forever. Unlike a closed scope, detached execution may publish local/headless state without waking a host.