pub unsafe trait NSItemProviderCKSharingSupport:
ClassType
+ Sized
+ Sealed {
// Provided methods
unsafe fn registerCKShareWithContainer_allowedSharingOptions_preparationHandler(
&self,
container: &CKContainer,
allowed_options: &CKAllowedSharingOptions,
preparation_handler: CKSharePreparationHandler,
) { ... }
unsafe fn registerCKShare_container_allowedSharingOptions(
&self,
share: &CKShare,
container: &CKContainer,
allowed_options: &CKAllowedSharingOptions,
) { ... }
}NSItemProvider_CKSharingSupport only.Expand description
Category “CKSharingSupport” on NSItemProvider.
Provided Methods§
Available on crate features CKAllowedSharingOptions and CKContainer and CKRecord and CKShare and block2 only.
CKAllowedSharingOptions and CKContainer and CKRecord and CKShare and block2 only.Use this method when you want to share a collection of
CKRecordsbut don’t currently have a
CKShare.When the
preparationHandleris called, you should create a new
CKSharewith the appropriate root
CKRecordor
CKRecordZoneID.After ensuring the share and all records have been saved to the server, invoke the
preparationCompletionHandlerwith either the resulting
CKShare,or an
NSErrorif saving failed. Invoking the share sheet with a
CKShareregistered with this method will prompt the user to start sharing.
§Safety
preparation_handler must be a valid pointer.
Available on crate features CKAllowedSharingOptions and CKContainer and CKRecord and CKShare only.
CKAllowedSharingOptions and CKContainer and CKRecord and CKShare only.Use this method when you have a
CKSharethat is already saved to the server. Invoking the share sheet with a
CKShareregistered with this method will allow the owner to make modifications to the share settings, or will allow a participant to view the share settings.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.