SchemaChangeInfo


class SchemaChangeInfo


Contains information about a schema change detected by an ObserverCallback.

This object will be sent when a schema type having a name matching an observer's schema filters (as determined by getFilterSchemas) has been added, updated, or removed.

Note that schema changes may cause documents to be migrated or removed. When this happens, individual document updates will NOT be dispatched via DocumentChangeInfo. The only notification will be of the schema type change via SchemaChangeInfo. Depending on your use case, you may need to re-query the whole schema type when this happens.

Summary

Public constructors

SchemaChangeInfo(
    packageName: String,
    databaseName: String,
    changedSchemaNames: (Mutable)Set<String!>
)

Constructs a new SchemaChangeInfo.

Public functions

Boolean
equals(o: Any?)
(Mutable)Set<String!>

Returns the names of schema types affected by this change notification.

String

Returns the database in which the schema that was changed resides.

String

Returns the package name of the app which owns the schema that changed.

Int
String

Public constructors

SchemaChangeInfo

Added in 1.1.0-alpha07
SchemaChangeInfo(
    packageName: String,
    databaseName: String,
    changedSchemaNames: (Mutable)Set<String!>
)

Constructs a new SchemaChangeInfo.

Parameters
packageName: String

The package name of the app which owns the schema that changed.

databaseName: String

The database in which the schema that changed resides.

changedSchemaNames: (Mutable)Set<String!>

Names of schemas that have changed as part of this notification.

Public functions

equals

fun equals(o: Any?): Boolean

getChangedSchemaNames

Added in 1.1.0-alpha07
fun getChangedSchemaNames(): (Mutable)Set<String!>

Returns the names of schema types affected by this change notification.

This will never be empty.

getDatabaseName

Added in 1.1.0-alpha07
fun getDatabaseName(): String

Returns the database in which the schema that was changed resides.

getPackageName

Added in 1.1.0-alpha07
fun getPackageName(): String

Returns the package name of the app which owns the schema that changed.

hashCode

fun hashCode(): Int

toString

fun toString(): String