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 unsafe fn initWithURL(this: Allocated<Self>, url: &NSURL) -> Retained<Self>;
36
37 #[cfg(all(feature = "UIDragItem", feature = "UIDragSession", feature = "block2"))]
38 #[unsafe(method(dragItemsProvider))]
42 #[unsafe(method_family = none)]
43 pub unsafe fn dragItemsProvider(
44 &self,
45 ) -> *mut block2::DynBlock<
46 dyn Fn(NonNull<ProtocolObject<dyn UIDragSession>>) -> NonNull<NSArray<UIDragItem>>,
47 >;
48
49 #[cfg(all(feature = "UIDragItem", feature = "UIDragSession", feature = "block2"))]
50 #[unsafe(method(setDragItemsProvider:))]
52 #[unsafe(method_family = none)]
53 pub unsafe fn setDragItemsProvider(
54 &self,
55 drag_items_provider: Option<
56 &block2::DynBlock<
57 dyn Fn(
58 NonNull<ProtocolObject<dyn UIDragSession>>,
59 ) -> NonNull<NSArray<UIDragItem>>,
60 >,
61 >,
62 );
63
64 #[cfg(all(
65 feature = "UIActivityViewController",
66 feature = "UIResponder",
67 feature = "UIViewController",
68 feature = "block2"
69 ))]
70 #[unsafe(method(activityViewControllerProvider))]
72 #[unsafe(method_family = none)]
73 pub unsafe fn activityViewControllerProvider(
74 &self,
75 ) -> *mut block2::DynBlock<dyn Fn() -> NonNull<UIActivityViewController>>;
76
77 #[cfg(all(
78 feature = "UIActivityViewController",
79 feature = "UIResponder",
80 feature = "UIViewController",
81 feature = "block2"
82 ))]
83 #[unsafe(method(setActivityViewControllerProvider:))]
85 #[unsafe(method_family = none)]
86 pub unsafe fn setActivityViewControllerProvider(
87 &self,
88 activity_view_controller_provider: Option<
89 &block2::DynBlock<dyn Fn() -> NonNull<UIActivityViewController>>,
90 >,
91 );
92
93 #[unsafe(method(wantsIconRepresentation))]
95 #[unsafe(method_family = none)]
96 pub unsafe fn wantsIconRepresentation(&self) -> bool;
97
98 #[unsafe(method(setWantsIconRepresentation:))]
100 #[unsafe(method_family = none)]
101 pub unsafe fn setWantsIconRepresentation(&self, wants_icon_representation: bool);
102 );
103}