1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
//! This file has been automatically generated by `objc2`'s `header-translator`.
//! DO NOT EDIT
use core::ptr::NonNull;
use objc2::__framework_prelude::*;
use crate::*;
extern_protocol!(
/// A protocol which must be adopted by the class set as extension's `NSExtensionPrincipalClass`.
///
/// See also [Apple's documentation](https://developer.apple.com/documentation/mailkit/meextension?language=objc)
pub unsafe trait MEExtension: NSObjectProtocol + MainThreadOnly {
#[cfg(feature = "MEComposeSession")]
/// A factory method for returning an instance of
/// `MEComposeSessionHandler`
/// Parameter `session`: An instance of
/// `MEComposeSession`that represents a mail compose window.
#[optional]
#[unsafe(method(handlerForComposeSession:))]
#[unsafe(method_family = none)]
unsafe fn handlerForComposeSession(
&self,
session: &MEComposeSession,
) -> Retained<ProtocolObject<dyn MEComposeSessionHandler>>;
#[cfg(feature = "MEMessageActionHandler")]
/// A factory method for returning an instance of
/// `MEMessageActionHandler`
#[optional]
#[unsafe(method(handlerForMessageActions))]
#[unsafe(method_family = none)]
unsafe fn handlerForMessageActions(
&self,
) -> Retained<ProtocolObject<dyn MEMessageActionHandler>>;
#[cfg(feature = "MEContentBlocker")]
/// A factory method for returning an instance of
/// `MEContentBlocker`
#[optional]
#[unsafe(method(handlerForContentBlocker))]
#[unsafe(method_family = none)]
unsafe fn handlerForContentBlocker(&self)
-> Retained<ProtocolObject<dyn MEContentBlocker>>;
#[cfg(all(
feature = "MEMessageDecoder",
feature = "MEMessageEncoder",
feature = "MEMessageSecurityHandler"
))]
/// A factory method for returning an instance of
/// `MEMessageSecurityHandler`
#[optional]
#[unsafe(method(handlerForMessageSecurity))]
#[unsafe(method_family = none)]
unsafe fn handlerForMessageSecurity(
&self,
) -> Retained<ProtocolObject<dyn MEMessageSecurityHandler>>;
}
);