objc2_ui_kit/generated/
UINib.rs

1//! This file has been automatically generated by `objc2`'s `header-translator`.
2//! DO NOT EDIT
3use core::ptr::NonNull;
4use objc2::__framework_prelude::*;
5use objc2_foundation::*;
6
7use crate::*;
8
9extern_class!(
10    /// [Apple's documentation](https://developer.apple.com/documentation/uikit/uinib?language=objc)
11    #[unsafe(super(NSObject))]
12    #[thread_kind = MainThreadOnly]
13    #[derive(Debug, PartialEq, Eq, Hash)]
14    #[deprecated = "Loading Interface Builder products will not be supported in a future version of visionOS."]
15    pub struct UINib;
16);
17
18unsafe impl NSObjectProtocol for UINib {}
19
20impl UINib {
21    extern_methods!(
22        #[deprecated = "Loading Interface Builder products will not be supported in a future version of visionOS."]
23        #[unsafe(method(nibWithNibName:bundle:))]
24        #[unsafe(method_family = none)]
25        pub unsafe fn nibWithNibName_bundle(
26            name: &NSString,
27            bundle_or_nil: Option<&NSBundle>,
28            mtm: MainThreadMarker,
29        ) -> Retained<UINib>;
30
31        #[deprecated = "Loading Interface Builder products will not be supported in a future version of visionOS."]
32        #[unsafe(method(nibWithData:bundle:))]
33        #[unsafe(method_family = none)]
34        pub unsafe fn nibWithData_bundle(
35            data: &NSData,
36            bundle_or_nil: Option<&NSBundle>,
37            mtm: MainThreadMarker,
38        ) -> Retained<UINib>;
39
40        #[cfg(feature = "UINibLoading")]
41        #[deprecated = "Loading Interface Builder products will not be supported in a future version of visionOS."]
42        #[unsafe(method(instantiateWithOwner:options:))]
43        #[unsafe(method_family = none)]
44        pub unsafe fn instantiateWithOwner_options(
45            &self,
46            owner_or_nil: Option<&AnyObject>,
47            options_or_nil: Option<&NSDictionary<UINibOptionsKey, AnyObject>>,
48        ) -> Retained<NSArray>;
49    );
50}
51
52/// Methods declared on superclass `NSObject`.
53impl UINib {
54    extern_methods!(
55        #[unsafe(method(init))]
56        #[unsafe(method_family = init)]
57        pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
58
59        #[unsafe(method(new))]
60        #[unsafe(method_family = new)]
61        pub unsafe fn new(mtm: MainThreadMarker) -> Retained<Self>;
62    );
63}