cloudkit_sync library
A thin bridge to CloudKit's CKSyncEngine for the private database.
This library is separate from the document storage API in
icloud_storage.dart; it uses CloudKit only and never touches the iCloud
Drive ubiquity container. Requires iOS 17 or macOS 14.
Classes
- CloudKitAccountChange
- The device's iCloud account changed.
- CloudKitAssetStore
-
Moves single assets to and from the CloudKit private database, outside
CloudKitSyncEngine. - CloudKitErrorCode
-
CKError.Coderaw values that an app acts on. Compare any other code with its raw value from Apple'sCKError.Codedocumentation. - CloudKitFailedRecordDelete
- A record delete that failed.
- CloudKitFailedRecordSave
- A record save that failed.
- CloudKitFailedZoneChange
- A zone save or delete that failed.
- CloudKitFetchedDatabaseChanges
- Zones changed or were deleted.
- CloudKitFetchedRecordZoneChanges
- One batch of record changes fetched from the server.
- CloudKitItemError
- A CloudKit error for one record or zone.
- CloudKitPendingDatabaseChange
- A zone change for the engine to send.
- CloudKitPendingRecordDelete
- Delete the record with id.
- CloudKitPendingRecordSave
- Save the record with id.
- CloudKitPendingRecordZoneChange
- A record change for the engine to send.
- CloudKitPendingZoneDelete
- Delete the zone and every record in it.
- CloudKitPendingZoneSave
- Create the zone, or keep it when it exists.
- CloudKitRecord
- A CloudKit record as it crosses the bridge.
- CloudKitRecordDeletion
- A record deleted on the server.
- CloudKitRecordId
- Identity of a CloudKit record in a zone of the private database.
- CloudKitRecordZoneChangeBatch
- The records for one request the engine sends.
- CloudKitSentDatabaseChanges
- Results of sending zone changes.
- CloudKitSentRecordZoneChanges
- Results of sending one CloudKitRecordZoneChangeBatch.
- CloudKitStateUpdate
-
The engine state changed. Save stateSerialization together with the
changes already handled and pass it to the next
CloudKitSyncEngine.start. - CloudKitSyncDelegate
- Receives a CloudKitSyncEngine's events and supplies the records it sends.
- CloudKitSyncEngine
-
Syncs the CloudKit private database of a container through Apple's
CKSyncEngine. - CloudKitSyncEvent
-
Something
CKSyncEnginereported. Each subtype mirrors oneCKSyncEngine.Eventcase. - CloudKitZoneDeletion
- One zone deletion.
Enums
- CloudKitAccountChangeType
- How the device's iCloud account changed.
- CloudKitAccountStatus
-
The iCloud account status of a container, mirroring
CKAccountStatus. - CloudKitZoneDeletionReason
- Why a zone was deleted.
Exceptions / Errors
- CloudKitSyncException
- A failure reported by the CloudKit sync bridge.