SetChange
This sealed interface describes the possible changes that can happen to a RealmSet collection.
The states are represented by the specific subclasses InitialSet, UpdatedSet and DeletedSet. When the set is deleted an empty set is emitted instead of null
.
Since sets do not expose indices your UI components will have to manually handle updates:
person.addresses.asFlow()
.collect { setChange: SetChange<Address> ->
handleChange(setChange.set)
}
Content copied to clipboard