objc2_class_kit/generated/CLSContextProvider.rs
1//! This file has been automatically generated by `objc2`'s `header-translator`.
2//! DO NOT EDIT
3use core::ffi::*;
4use core::ptr::NonNull;
5use objc2::__framework_prelude::*;
6use objc2_foundation::*;
7
8use crate::*;
9
10extern_protocol!(
11 /// The CLSContext provider protocol.
12 ///
13 /// The app extension that provides CLSContexts should adopt this protocol.
14 ///
15 /// See also [Apple's documentation](https://developer.apple.com/documentation/classkit/clscontextprovider?language=objc)
16 pub unsafe trait CLSContextProvider {
17 #[cfg(all(feature = "CLSContext", feature = "CLSObject", feature = "block2"))]
18 /// This method asks the app extension to update CLSContexts that are descendants of a given context.
19 ///
20 /// Parameter `context`: A CLSContext whose descendants are to be updated
21 ///
22 /// Parameter `completion`: A completion block the extension should call with an optional error to indicate success or failure.
23 ///
24 /// The extension may choose to modify, delete, or create some or all descendants of the given context. The host app may call this method as the user selects a context.
25 #[unsafe(method(updateDescendantsOfContext:completion:))]
26 #[unsafe(method_family = none)]
27 unsafe fn updateDescendantsOfContext_completion(
28 &self,
29 context: &CLSContext,
30 completion: &block2::DynBlock<dyn Fn(*mut NSError)>,
31 );
32 }
33);