ContentObservable
open class ContentObservable : Observable<ContentObserver!>
kotlin.Any | ||
↳ | android.database.Observable<android.database.ContentObserver> | |
↳ | android.database.ContentObservable |
A specialization of Observable
for ContentObserver
that provides methods for sending notifications to a list of ContentObserver
objects.
Summary
Public constructors | |
---|---|
Public methods | |
---|---|
open Unit |
dispatchChange(selfChange: Boolean) Invokes |
open Unit |
dispatchChange(selfChange: Boolean, uri: Uri!) Invokes |
open Unit |
notifyChange(selfChange: Boolean) Invokes android. |
open Unit |
registerObserver(observer: ContentObserver!) |
Inherited functions | |
---|---|
Inherited properties | |
---|---|
Public constructors
ContentObservable
ContentObservable()
Public methods
dispatchChange
open fundispatchChange(selfChange: Boolean): Unit
Deprecated: Use dispatchChange(boolean,android.net.Uri)
instead.
Invokes ContentObserver.dispatchChange(boolean)
on each observer.
If selfChange
is true, only delivers the notification to the observer if it has indicated that it wants to receive self-change notifications by implementing ContentObserver.deliverSelfNotifications
to return true.
Parameters | |
---|---|
selfChange |
Boolean: True if this is a self-change notification. |
dispatchChange
open fun dispatchChange(
selfChange: Boolean,
uri: Uri!
): Unit
Invokes ContentObserver.dispatchChange(boolean, Uri)
on each observer. Includes the changed content Uri when available.
If selfChange
is true, only delivers the notification to the observer if it has indicated that it wants to receive self-change notifications by implementing ContentObserver.deliverSelfNotifications
to return true.
Parameters | |
---|---|
selfChange |
Boolean: True if this is a self-change notification. |
uri |
Uri!: The Uri of the changed content, or null if unknown. |
notifyChange
open funnotifyChange(selfChange: Boolean): Unit
Deprecated: Use #dispatchChange instead.
Invokes android.database.ContentObserver#onChange on each observer.
Parameters | |
---|---|
selfChange |
Boolean: True if this is a self-change notification. |
registerObserver
open fun registerObserver(observer: ContentObserver!): Unit
Parameters | |
---|---|
observer |
ContentObserver!: the observer to register |
Exceptions | |
---|---|
java.lang.IllegalArgumentException |
the observer is null |
java.lang.IllegalStateException |
the observer is already registered |