Package-level declarations

Types

Link copied to clipboard

Interface that defines an automatic sync client reset strategy, it could be either DiscardUnsyncedChangesStrategy, RecoverOrDiscardUnsyncedChangesStrategy or RecoverUnsyncedChangesStrategy.

Link copied to clipboard

Base interface for shared functionality between SubscriptionSet and MutableSubscriptionSet.

Link copied to clipboard

A connection state indicates the state of the underlying connection of the SyncSession.

Link copied to clipboard
data class ConnectionStateChange(val oldState: ConnectionState, val newState: ConnectionState)

A connection state change indicates a change in the SyncSession's underlying connection state.

Link copied to clipboard

A direction indicates whether a given Progress-flow created with SyncSession.progressAsFlow is reporting changes when either uploading or downloading data.

Link copied to clipboard

Strategy that automatically resolves a Client Reset by discarding any unsynced local data but otherwise keeps the realm open. Any changes will be reported through the normal collection and object notifications.

Link copied to clipboard
data class InitialRemoteDataConfiguration(val timeout: Duration = Duration.INFINITE)

Configuration options if SyncConfiguration.Builder.waitForInitialRemoteData is enabled.

Link copied to clipboard

Callback used to populate the initial SubscriptionSet when opening a Realm.

Link copied to clipboard
data class InitialSubscriptionsConfiguration(val callback: InitialSubscriptionsCallback, val rerunOnOpen: Boolean)

Configuration options if SyncConfiguration.Builder.initialSubscriptions is enabled.

Link copied to clipboard

Strategy to manually resolve a Client Reset.

Link copied to clipboard

A mutable subscription set makes it possible to add, remove or modify a SubscriptionSet. It becomes available when calling SubscriptionSet.update.

Link copied to clipboard
data class Progress(val transferredBytes: ULong, val transferableBytes: ULong)

A progress indicator emitted by flows created from SyncSession.progressAsFlow.

Link copied to clipboard

A progress mode is used to select which notifications are received from SyncSession.progressAsFlow.

Link copied to clipboard

Strategy that attempts to automatically recover any unsynced changes during a Client Reset, if the recovery fails the changes would be discarded.

Link copied to clipboard

Strategy that attempts to automatically recover any unsynced changes during a Client Reset.

Link copied to clipboard
interface Subscription

A subscription defines a specific server query and its metadata. The result of this query is continuously being synchronized with the device as long as the subscription is part of a SubscriptionSet with a state of SubscriptionSetState.COMPLETE.

Link copied to clipboard

A subscription set is an immutable view of all current Subscriptions for a given Realm that has been configured for Flexible Sync.

Link copied to clipboard
Link copied to clipboard
interface Sync

A Device Sync manager responsible for controlling all sync sessions across all realms associated with a given App instance. For session functionality associated with a single realm, see syncSession.

Link copied to clipboard

Interface that defines a generic sync client reset strategy. It can be either ManuallyRecoverUnsyncedChangesStrategy or DiscardUnsyncedChangesStrategy.

Link copied to clipboard

A SyncConfiguration is used to setup a Realm Database that can be synchronized between devices using Atlas Device Sync.

Link copied to clipboard

This enum determines how Realm sync data with the server.

Link copied to clipboard
interface SyncSession

A session controls how data is synchronized between a single Realm on the device and MongoDB on the server.

Link copied to clipboard
data class SyncTimeoutOptions(val connectTimeout: Duration, val connectionLingerTime: Duration, val pingKeepalivePeriod: Duration, val pongKeepalivePeriod: Duration, val fastReconnectLimit: Duration)

The configured timeouts for various aspects of the sync connection between synchronized realms and App Services.

Link copied to clipboard

Builder for configuring various timeouts related to the sync connection to the server.

Link copied to clipboard

Enum defining the behaviour of when RealmQuery.subscribe and RealmResults.subscribe will return a query result.

Functions

Link copied to clipboard

Converts the Subscription.queryDescription back to a RealmQuery that can be executed against the local Realm.