pub unsafe trait NSItemProviderNSCloudKitSharing:
ClassType
+ Sized
+ Sealed {
// Provided methods
unsafe fn registerCloudKitShareWithPreparationHandler(
&self,
preparation_handler: &DynBlock<dyn Fn(NonNull<DynBlock<dyn Fn(*mut CKShare, *mut CKContainer, *mut NSError)>>)>,
) { ... }
fn registerCloudKitShare_container(
&self,
share: &CKShare,
container: &CKContainer,
) { ... }
}NSSharingService only.Expand description
Category “NSCloudKitSharing” on NSItemProvider.
Provided Methods§
Available on crate feature block2 and crate feature objc2-cloud-kit and Apple only.
block2 and crate feature objc2-cloud-kit and Apple only.Use this method when you want to share a collection of CKRecords but don’t currently have a CKShare. When the preparationHandler is called, you should create a new CKShare with the appropriate root CKRecord. After ensuring the share and all records have been saved to the server, invoke the preparationCompletionHandler with either the resulting CKShare and its CKContainer, or an NSError if saving failed. Invoking the service with a CKShare registered with this method will prompt the user to start sharing.
§Safety
preparation_handlerblock’s argument block’s argument 1 must be a valid pointer or null.preparation_handlerblock’s argument block’s argument 2 must be a valid pointer or null.preparation_handlerblock’s argument block’s argument 3 must be a valid pointer or null.
Available on crate feature objc2-cloud-kit and Apple only.
objc2-cloud-kit and Apple only.Use this method when you have a CKShare that is already saved to the server. Invoking the service with a CKShare registerd 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.