ObserverCallback


public interface ObserverCallback


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

Summary

Public methods

abstract void

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

abstract void

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

Public methods

onDocumentChanged

Added in 1.1.0-alpha06
abstract void onDocumentChanged(@NonNull DocumentChangeInfo changeInfo)

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

Parameters
@NonNull DocumentChangeInfo changeInfo

Information about the nature of the change.

onSchemaChanged

Added in 1.1.0-alpha06
abstract void onSchemaChanged(@NonNull SchemaChangeInfo changeInfo)

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

Parameters
@NonNull SchemaChangeInfo changeInfo

Information about the nature of the change.