objc2_ui_kit/generated/
UIMailConversationEntry.rs1use core::ffi::*;
4use core::ptr::NonNull;
5use objc2::__framework_prelude::*;
6use objc2_foundation::*;
7
8use crate::*;
9
10#[repr(transparent)]
15#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord)]
16pub struct UIMailConversationEntryKind(pub NSInteger);
17impl UIMailConversationEntryKind {
18 #[doc(alias = "UIMailConversationEntryKindNone")]
20 pub const None: Self = Self(0);
21 #[doc(alias = "UIMailConversationEntryKindPersonal")]
23 pub const Personal: Self = Self(1);
24 #[doc(alias = "UIMailConversationEntryKindPromotion")]
26 pub const Promotion: Self = Self(2);
27 #[doc(alias = "UIMailConversationEntryKindSocial")]
29 pub const Social: Self = Self(3);
30 #[doc(alias = "UIMailConversationEntryKindTransaction")]
32 pub const Transaction: Self = Self(4);
33 #[doc(alias = "UIMailConversationEntryKindNews")]
35 pub const News: Self = Self(5);
36}
37
38unsafe impl Encode for UIMailConversationEntryKind {
39 const ENCODING: Encoding = NSInteger::ENCODING;
40}
41
42unsafe impl RefEncode for UIMailConversationEntryKind {
43 const ENCODING_REF: Encoding = Encoding::Pointer(&Self::ENCODING);
44}
45
46extern_class!(
47 #[unsafe(super(UIConversationEntry, NSObject))]
51 #[derive(Debug, PartialEq, Eq, Hash)]
52 #[cfg(feature = "UIConversationEntry")]
53 pub struct UIMailConversationEntry;
54);
55
56#[cfg(feature = "UIConversationEntry")]
57extern_conformance!(
58 unsafe impl NSObjectProtocol for UIMailConversationEntry {}
59);
60
61#[cfg(feature = "UIConversationEntry")]
62impl UIMailConversationEntry {
63 extern_methods!(
64 #[unsafe(method(kind))]
66 #[unsafe(method_family = none)]
67 pub unsafe fn kind(&self) -> UIMailConversationEntryKind;
68
69 #[unsafe(method(setKind:))]
71 #[unsafe(method_family = none)]
72 pub unsafe fn setKind(&self, kind: UIMailConversationEntryKind);
73
74 #[unsafe(method(responseSecondaryRecipientIdentifiers))]
76 #[unsafe(method_family = none)]
77 pub unsafe fn responseSecondaryRecipientIdentifiers(&self) -> Retained<NSSet<NSString>>;
78
79 #[unsafe(method(setResponseSecondaryRecipientIdentifiers:))]
81 #[unsafe(method_family = none)]
82 pub unsafe fn setResponseSecondaryRecipientIdentifiers(
83 &self,
84 response_secondary_recipient_identifiers: &NSSet<NSString>,
85 );
86 );
87}
88
89#[cfg(feature = "UIConversationEntry")]
91impl UIMailConversationEntry {
92 extern_methods!(
93 #[unsafe(method(init))]
94 #[unsafe(method_family = init)]
95 pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
96
97 #[unsafe(method(new))]
98 #[unsafe(method_family = new)]
99 pub unsafe fn new() -> Retained<Self>;
100 );
101}