objc2_ui_kit/generated/
UIDocumentProperties.rs1use core::ffi::*;
4use core::ptr::NonNull;
5use objc2::__framework_prelude::*;
6use objc2_foundation::*;
7
8use crate::*;
9
10extern_class!(
11 #[unsafe(super(NSObject))]
13 #[thread_kind = MainThreadOnly]
14 #[derive(Debug, PartialEq, Eq, Hash)]
15 pub struct UIDocumentProperties;
16);
17
18extern_conformance!(
19 unsafe impl NSObjectProtocol for UIDocumentProperties {}
20);
21
22impl UIDocumentProperties {
23 extern_methods!(
24 #[unsafe(method(init))]
25 #[unsafe(method_family = init)]
26 pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
27
28 #[unsafe(method(new))]
29 #[unsafe(method_family = new)]
30 pub unsafe fn new(mtm: MainThreadMarker) -> Retained<Self>;
31
32 #[unsafe(method(initWithURL:))]
34 #[unsafe(method_family = init)]
35 pub fn initWithURL(this: Allocated<Self>, url: &NSURL) -> Retained<Self>;
36
37 #[cfg(all(feature = "UIDragItem", feature = "UIDragSession", feature = "block2"))]
38 #[unsafe(method(dragItemsProvider))]
46 #[unsafe(method_family = none)]
47 pub unsafe fn dragItemsProvider(
48 &self,
49 ) -> *mut block2::DynBlock<
50 dyn Fn(NonNull<ProtocolObject<dyn UIDragSession>>) -> NonNull<NSArray<UIDragItem>>,
51 >;
52
53 #[cfg(all(feature = "UIDragItem", feature = "UIDragSession", feature = "block2"))]
54 #[unsafe(method(setDragItemsProvider:))]
62 #[unsafe(method_family = none)]
63 pub unsafe fn setDragItemsProvider(
64 &self,
65 drag_items_provider: Option<
66 &block2::DynBlock<
67 dyn Fn(
68 NonNull<ProtocolObject<dyn UIDragSession>>,
69 ) -> NonNull<NSArray<UIDragItem>>,
70 >,
71 >,
72 );
73
74 #[cfg(all(
75 feature = "UIActivityViewController",
76 feature = "UIResponder",
77 feature = "UIViewController",
78 feature = "block2"
79 ))]
80 #[unsafe(method(activityViewControllerProvider))]
82 #[unsafe(method_family = none)]
83 pub fn activityViewControllerProvider(
84 &self,
85 ) -> *mut block2::DynBlock<dyn Fn() -> NonNull<UIActivityViewController>>;
86
87 #[cfg(all(
88 feature = "UIActivityViewController",
89 feature = "UIResponder",
90 feature = "UIViewController",
91 feature = "block2"
92 ))]
93 #[unsafe(method(setActivityViewControllerProvider:))]
101 #[unsafe(method_family = none)]
102 pub unsafe fn setActivityViewControllerProvider(
103 &self,
104 activity_view_controller_provider: Option<
105 &block2::DynBlock<dyn Fn() -> NonNull<UIActivityViewController>>,
106 >,
107 );
108
109 #[unsafe(method(wantsIconRepresentation))]
111 #[unsafe(method_family = none)]
112 pub fn wantsIconRepresentation(&self) -> bool;
113
114 #[unsafe(method(setWantsIconRepresentation:))]
116 #[unsafe(method_family = none)]
117 pub fn setWantsIconRepresentation(&self, wants_icon_representation: bool);
118 );
119}