ObservableListImpl

Properties

Link copied to clipboard
open override val changed: ListObservers<ObservableList<E>, E>

Notifies of changes to the list

Inherited properties

Link copied to clipboard
open override val size: Int

Functions

Link copied to clipboard
open override fun add(element: E): Boolean
open override fun add(index: Int, element: E)
Link copied to clipboard
open override fun addAll(elements: Collection<E>): Boolean
open override fun addAll(index: Int, elements: Collection<E>): Boolean
Link copied to clipboard
open override fun <T> batch(block: MutableList<E>.() -> T): T

Runs the operations within block and then applies them all to the list as a single operation. This reduces the set of events that would normally trigger if these operations were done sequentially.

Link copied to clipboard
open override fun clear()
Link copied to clipboard
open operator override fun iterator(): MutableIterator<E>
Link copied to clipboard
open operator override fun minusAssign(element: E)

Removes element from the list

Link copied to clipboard
open override fun move(element: E, to: Int): Boolean

Moves element to a new index.

Link copied to clipboard
open override fun notifyChanged(index: Int)

Explicitly trigger a diff that shows the element at index being deleted and re-added. This is useful for cases where the elements in the list are mutable and a change has happened to one that would normally not result in a call to changed (which only notifies of membership changes.

Link copied to clipboard
open operator override fun plusAssign(element: E)

Adds element to the list

Link copied to clipboard
open override fun remove(element: E): Boolean
Link copied to clipboard
open override fun removeAll(elements: Collection<E>): Boolean
Link copied to clipboard
open override fun removeAt(index: Int): E
Link copied to clipboard
open override fun replaceAll(elements: Collection<E>): Boolean

Replaces the list's contents with elements.

Link copied to clipboard
open override fun retainAll(elements: Collection<E>): Boolean
Link copied to clipboard
open operator override fun set(index: Int, element: E): E

Inherited functions

Link copied to clipboard
fun <T> MutableList<T>.addOrAppend(at: Int, value: T)

Ads value to the list at the specify index, or at the end of the list if that index exceeds the current list length.

Link copied to clipboard
fun Collection<Completable>.allCompleted(completed: () -> Unit)
Link copied to clipboard
open operator override fun contains(element: E): Boolean
Link copied to clipboard
operator fun <E> Collection<E>?.contains(element: E): Boolean

Nullable helper

Link copied to clipboard
open override fun containsAll(elements: Collection<E>): Boolean
Link copied to clipboard
open operator override fun get(index: Int): E
Link copied to clipboard
open override fun indexOf(element: E): Int
Link copied to clipboard
open override fun isEmpty(): Boolean
Link copied to clipboard
open override fun lastIndexOf(element: E): Int
Link copied to clipboard
open override fun listIterator(): MutableListIterator<E>
open override fun listIterator(index: Int): MutableListIterator<E>
Link copied to clipboard
fun <T> ObservableList<T>.sortWith(comparator: Comparator<in T>)
Link copied to clipboard
Link copied to clipboard
open override fun subList(fromIndex: Int, toIndex: Int): MutableList<E>