MultipleSelector

class MultipleSelector<T>(selectedItems: List<T> = emptyList(), safeChanges: Boolean = true) : Selector<T>

Realization of Selector with multiple selected elements. On calling of toggleSelection this realization will select passed element OR deselect it if it is already in selectedItems

Parameters

safeChanges

Set to false to disable using of mutex for synchronizing changes on toggleSelection

Constructors

Link copied to clipboard
fun <T> MultipleSelector(selectedItems: List<T> = emptyList(), safeChanges: Boolean = true)

Functions

Link copied to clipboard
open suspend override fun clearSelection()
Link copied to clipboard
open suspend override fun forceDeselect(element: T)
Link copied to clipboard
open suspend override fun forceSelect(element: T)
Link copied to clipboard
open suspend override fun toggleSelection(element: T)

Properties

Link copied to clipboard
open override val itemSelected: SharedFlow<T>
Link copied to clipboard
open override val itemUnselected: SharedFlow<T>
Link copied to clipboard
open override val selectedItems: List<T>