Instance Method


Executes the specified operation asynchronously against the current database.


func add(_ operation: CKDatabaseOperation)



The operation object to execute. You must configure the operation object with any dependencies and completion handlers before calling this method. If this parameter is nil, the method does nothing.


Do not change the properties of the operation object after calling this method. Prior to executing the operation, this method sets the operation object’s database property to the current database, replacing any previously assigned database.

This method executes the operation object with the priority you assigned to the object through its queuePriority property.

Beta Software

This documentation contains preliminary information about an API or technology in development. This information is subject to change, and software implemented according to this documentation should be tested with final operating system software.

Learn more about using Apple's beta software