Class SyncStatus
public class SyncStatus
- Inheritance
-
SyncStatus
- Inherited Members
Constructors
Properties
- DataFlowStatus
Upload/download status.
- HasSynced
Indicates whether there has been at least one full sync. Is null when unknown, for example when state is still being loaded from the database.
- LastSyncedAt
Time that the last sync has fully completed, if any. Currently, this is reset to null after a restart.
- PriorityStatusEntries
Provides sync status information for all bucket priorities, sorted by priority (highest first).
- SyncStreams
All sync streams currently being tracked in the database. This returns null when the database is currently being opened and we don't have reliable information about all included streams yet.
Sync streams are currently in alpha.
Methods
- CreateUpdatedStatus(SyncStatus)
Creates an updated SyncStatus by merging the current status with the provided updated status.
- DownloadProgress()
A realtime progress report on how many operations have been downloaded and how many are necessary in total to complete the next sync iteration.
- ForStream(ISyncStreamDescription)
If the stream appears in SyncStreams, returns the current status for that stream.
Sync streams are currently in alpha.
- StatusForPriority(int)
Reports the sync status (a pair of HasSynced and LastSyncedAt fields) for a specific bucket priority level.
When buckets with different priorities are declared, PowerSync may choose to synchronize higher-priority buckets first. When a consistent view over all buckets for all priorities up until the given priority is reached, PowerSync makes data from those buckets available before lower-priority buckets have finished syncing.
This method returns the status for the requested priority or the next higher priority level that has status information available. This is because when PowerSync makes data for a given priority available, all buckets in higher-priorities are guaranteed to be consistent with that checkpoint. For example, if PowerSync just finished synchronizing buckets in priority level 3, calling this method with a priority of 1 may return information for priority level 3.