Package-level declarations

Types

Link copied to clipboard
interface MutableReactiveCollection<E, out IC, out MC : IC>

A foundational interface for mutable collections that expose their state as a StateFlow.

Link copied to clipboard

A mutable list that also exposes a StateFlow via asStateFlow, allowing for reactive observation of its contents.

Link copied to clipboard

A mutable map that also exposes a StateFlow via asStateFlow, allowing for reactive observation of its contents.

Link copied to clipboard

A mutable set that also exposes a StateFlow via asStateFlow, allowing for reactive observation of its contents.

Functions

Link copied to clipboard
fun <E> MutableReactiveList<E>.getAsFlow(index: Int): Flow<E?>

Creates a Flow that emits the element at the specified index whenever the list changes.

Link copied to clipboard
fun <E> MutableReactiveList<E>.subListAsFlow(fromIndex: Int, toIndex: Int, strict: Boolean = true): Flow<List<E>>

Returns a Flow that emits a sublist view of this reactive list between the specified fromIndex (inclusive) and toIndex (exclusive).

Link copied to clipboard
fun <K, V> MutableReactiveMap<K, V>.valueAsFlow(key: K): Flow<V?>

Creates a Flow that emits the value associated with the specified key whenever this map changes.