sync library

Classes

ClientWinsResolver<T>
Always chooses the local document, making the client authoritative.
ConflictResolver<T>
Strategy for resolving write conflicts between a local and a remote version of the same document.
FieldMergeResolver<T>
Resolves conflicts at the field level using per-field timestamps.
HivePendingChangeStore
A Hive-backed alternative to PendingChangeStore for persisting SyncChange objects across app restarts.
LastWriteWinsResolver<T>
Resolves conflicts by comparing the updatedAt ISO-8601 timestamp field.
ManualConflictResolver<T>
Defers conflict resolution to a user-supplied callback.
MongoSyncSource
A SyncDataSource backed by the MongoDB Atlas Data API (REST).
PendingChangeStore
Persists SyncChange objects to SharedPreferences so that unsynced local writes survive app restarts.
ServerWinsResolver<T>
Always chooses the remote document, making the server authoritative.
SyncChange
A single pending change waiting to be pushed to the remote backend.
SyncDataSource
Abstract remote backend used by SyncRepository.
SyncDocument
Base contract for any document that participates in offline sync.
SyncMeta
Immutable metadata attached to every synced document.
SyncRepository<T>
Generic offline-first repository that transparently persists data locally and synchronises with a remote SyncDataSource.
SyncState
Immutable snapshot of the sync engine's state at a point in time.
SyncStateManager
Manages SyncState transitions and broadcasts changes to listeners.

Enums

PkSyncStatus
The current synchronisation state of the app.
SyncOperation
The type of write operation applied to a document.
SyncStatus
The current phase of the sync state machine.

Extensions

PkSyncStatusX on PkSyncStatus