objc2_core_audio_kit/generated/
AUCustomViewPersistentData.rs

1//! This file has been automatically generated by `objc2`'s `header-translator`.
2//! DO NOT EDIT
3use core::ffi::*;
4use objc2::__framework_prelude::*;
5use objc2_foundation::*;
6
7use crate::*;
8
9extern_protocol!(
10    /// [Apple's documentation](https://developer.apple.com/documentation/coreaudiokit/aucustomviewpersistentdata?language=objc)
11    pub unsafe trait AUCustomViewPersistentData {
12        /// Property for accessing custom data to be preserved by the host
13        ///
14        /// Getter- Return the custom data to be preserved by the host before closing the view.                Setter- A NSDictionary containing the view data to restore when the view is opened. This property should set prior to opening the view. The au view should be written in such a way that it can store this dictionary and use its information when the view is opened and user interface elements are created. The view should retain this dictionary until it is finished with it, and should not release the dictionary. This dictionary is owned by the host.
15        ///
16        /// # Safety
17        ///
18        /// This is not retained internally, you must ensure the object is still alive.
19        #[unsafe(method(customViewPersistentData))]
20        #[unsafe(method_family = none)]
21        unsafe fn customViewPersistentData(
22            &self,
23        ) -> Option<Retained<NSDictionary<NSString, AnyObject>>>;
24
25        /// Setter for [`customViewPersistentData`][Self::customViewPersistentData].
26        ///
27        /// # Safety
28        ///
29        /// - `custom_view_persistent_data` generic should be of the correct type.
30        /// - This is unretained, you must ensure the object is kept alive while in use.
31        #[unsafe(method(setCustomViewPersistentData:))]
32        #[unsafe(method_family = none)]
33        unsafe fn setCustomViewPersistentData(
34            &self,
35            custom_view_persistent_data: Option<&NSDictionary<NSString, AnyObject>>,
36        );
37    }
38);