Docs Menu
Docs Home
/ /
Atlas Device SDKs
/ / /

Class CollectionChange

On this page

  • io.realm.rx
  • Constructors
  • Method Summary
  • Inherited Methods
  • Constructor Detail
  • Method Detail
  • equals
  • getChangeset
  • getCollection
  • hashCode

Container wrapping the result of a io.realm.OrderedRealmCollectionChangeListener being triggered.

This is used by RealmResults.asChangesetObservable() } and RealmList.asChangesetObservable() as RxJava is only capable of emitting one item, not multiple.

Constructor and Description

Constructor for a CollectionChange.

Modifier and Type
Method and Description
public boolean

Returns the changeset describing the update.

public E

Returns the collection that was updated.

public int
  • Methods inherited from class java.lang.Object : getClass , hashCode , equals , clone , toString , notify , notifyAll , wait , wait , wait , finalize

E collection,

Constructor for a CollectionChange.


  • collection - the collection that changed.

  • changeset - the changeset describing the change.

public boolean equals (


equals in class Object

Returns the changeset describing the update.This will be null the first time the stream emits the collection as well as when a asynchronous query is loaded for the first time.

// Example
.subscribe(new Consumer<CollectionChange>() {
public void accept(CollectionChange item) throws Exception {
item.getChangeset(); // Will return null the first two times


the changeset describing how the collection was updated.

public E getCollection ()

Returns the collection that was updated.


collection that was updated.

public int hashCode ()


hashCode in class Object

← io.realm.rx