subscribe
Creates an anonymous Subscription in the current MutableSubscriptionSet directly from a RealmQuery.
Return
the Subscription that was added.
open fun RealmQuery<out RealmObject>.subscribe(name: String, updateExisting: Boolean = false): Subscription
Creates a named Subscription in the current MutableSubscriptionSet directly from a RealmQuery.
Return
the Subscription that was added or updated.
Parameters
name
name of the subscription.
updateExisting
if a different query is already registered with the provided name, then set this to true
to update the subscription. If set to false
an exception is thrown instead of updating the query.
Throws
if updateExisting is false, and another query was already registered with the given name.