Skip to main content

Module runtime

Module runtime 

Source
Expand description

The runtime in which a composition runs: state cells, UI tasks, frame callbacks and the queue of invalidated scopes.

Structs§

DefaultScheduler
A scheduler that ignores frame requests, for compositions that the caller drives itself.
Runtime
Owns the state cells, UI tasks, frame callbacks and invalidated scopes of one composition. Clones share the same runtime.
RuntimeDebugStats
Sizes of a runtime’s queues and tables, for leak and memory checks. A _len field counts entries and a _cap field the capacity reserved.
RuntimeHandle
A cheap handle to a Runtime. It does not keep the runtime alive, and its calls do nothing once the runtime is dropped.
RuntimeId
Identifies a runtime within its thread.
RuntimeThreadLocalDebugStats
Sizes of the runtime registries of one thread, for leak and memory checks. A _len field counts entries and a _cap field the capacity reserved.
StateArenaDebugStats
Sizes of a runtime’s state arena, for leak and memory checks. A _len field counts entries and a _cap field the capacity reserved.
StateId
Names one state cell of a runtime. A generation count makes the id of a freed cell stale.
TaskHandle
Controls a future spawned with RuntimeHandle::spawn_ui.
UiDispatcher
Posts work from any thread to the UI thread of a runtime.

Functions§

current_runtime_handle
Gets the current runtime handle from thread-local storage.
debug_runtime_thread_local_stats
Returns the sizes of the runtime registries of the current thread, for leak and memory checks.
label_next_ui_task
Names the next task that spawn_ui creates on this thread, for live_ui_task_labels and leak reports. A task with no label is called unnamed.
schedule_frame
Schedule a new frame render using the most recently active runtime handle.
schedule_node_update
Schedule an in-place node update using the most recently active runtime.