ObserverCallback


interface ObserverCallback


An interface which apps can implement to subscribe to notifications of changes to AppSearch data.

Summary

Public functions

Unit

Callback to trigger after document changes (documents added, updated or removed).

Unit

Callback to trigger after schema changes (schema type added, updated or removed).

Public functions

onDocumentChanged

Added in 1.1.0-alpha06
fun onDocumentChanged(changeInfo: DocumentChangeInfo): Unit

Callback to trigger after document changes (documents added, updated or removed).

Parameters
changeInfo: DocumentChangeInfo

Information about the nature of the change.

onSchemaChanged

Added in 1.1.0-alpha06
fun onSchemaChanged(changeInfo: SchemaChangeInfo): Unit

Callback to trigger after schema changes (schema type added, updated or removed).

Parameters
changeInfo: SchemaChangeInfo

Information about the nature of the change.