Contents

initializeCloudKitSchema(options:)

Creates the CloudKit schema for all stores in the container that manage a CloudKit database.

Declaration

func initializeCloudKitSchema(options: NSPersistentCloudKitContainerSchemaInitializationOptions = []) throws

Parameters

  • options:

    The options to use when creating the CloudKit schema.

Discussion

To create the schema, this method creates a set of representative CKRecord instances for all stores in the container that use Core Data with CloudKit, and uploads them to CloudKit. These records have a representative value for every field Core Data might serialize for the specified managed object model. After successfully uploading the records, the schema is visible in the CloudKit Dashboard and the container deletes the representative records.

See Also

Promoting Your Schema