Contents

CKShare.Participant

An object that describes a user’s participation in a share.

Declaration

class Participant

Overview

Participants are a key element of sharing in CloudKit. A participant provides information about an iCloud user and their participation in a share, including their identity, acceptance status, permissions, and role.

The acceptance status determines the participant’s visibilty of the shared records. Statuses are: pending, accepted, removed, and unknown. If the status is pending, use CKAcceptSharesOperation to accept the share. Upon acceptance, CloudKit makes the shared records available in the participant’s shared database. The records remain accessible for as long as the participant’s status is accepted.

You don’t create participants. Use the share’s participants property to access its existing participants. Use UICloudSharingController to manage the share’s participants and their permissions. Alternatively, you can generate participants using CKFetchShareParticipantsOperation. Participants must have an active iCloud account.

Anyone with the URL of a public share can become a participant in that share. Participants of a public share assume the publicUser role. For private shares, the owner manages the participants. An owner is any participant with the owner role. A participant of a private share can’t accept the share unless the owner adds them first. Private share participants assume the privateUser role. CloudKit removes any pending participants if the owner changes the share’s publicPermission. CloudKit removes all participants if the new permission is none.

Participants with write permissions can modify or delete any record that you include in the share. However, only the owner can delete a shared hierarchy’s root record. If a participant attempts to delete the share, CloudKit removes the participant. The share remains active for all other participants.

Topics

Accessing the Participant’s Status

Accessing the Participant’s Identity

Managing the Participant’s Capabilites

Deprecated

Initializers

Instance Properties

Type Aliases

Type Methods

See Also

Participants