objc2_identity_lookup/generated/
ILClassificationResponse.rs

1//! This file has been automatically generated by `objc2`'s `header-translator`.
2//! DO NOT EDIT
3use core::ffi::*;
4use core::ptr::NonNull;
5use objc2::__framework_prelude::*;
6use objc2_foundation::*;
7
8use crate::*;
9
10extern_class!(
11    /// A response to an ILClassificationRequest.
12    ///
13    /// See also [Apple's documentation](https://developer.apple.com/documentation/identitylookup/ilclassificationresponse?language=objc)
14    #[unsafe(super(NSObject))]
15    #[derive(Debug, PartialEq, Eq, Hash)]
16    pub struct ILClassificationResponse;
17);
18
19extern_conformance!(
20    unsafe impl NSCoding for ILClassificationResponse {}
21);
22
23extern_conformance!(
24    unsafe impl NSObjectProtocol for ILClassificationResponse {}
25);
26
27extern_conformance!(
28    unsafe impl NSSecureCoding for ILClassificationResponse {}
29);
30
31impl ILClassificationResponse {
32    extern_methods!(
33        #[cfg(feature = "ILClassificationActions")]
34        #[unsafe(method(action))]
35        #[unsafe(method_family = none)]
36        pub unsafe fn action(&self) -> ILClassificationAction;
37
38        #[unsafe(method(userString))]
39        #[unsafe(method_family = none)]
40        pub unsafe fn userString(&self) -> Option<Retained<NSString>>;
41
42        /// Setter for [`userString`][Self::userString].
43        ///
44        /// This is [copied][objc2_foundation::NSCopying::copy] when set.
45        #[unsafe(method(setUserString:))]
46        #[unsafe(method_family = none)]
47        pub unsafe fn setUserString(&self, user_string: Option<&NSString>);
48
49        #[unsafe(method(userInfo))]
50        #[unsafe(method_family = none)]
51        pub unsafe fn userInfo(&self) -> Option<Retained<NSDictionary<NSString, AnyObject>>>;
52
53        /// Setter for [`userInfo`][Self::userInfo].
54        ///
55        /// This is [copied][objc2_foundation::NSCopying::copy] when set.
56        ///
57        /// # Safety
58        ///
59        /// `user_info` generic should be of the correct type.
60        #[unsafe(method(setUserInfo:))]
61        #[unsafe(method_family = none)]
62        pub unsafe fn setUserInfo(&self, user_info: Option<&NSDictionary<NSString, AnyObject>>);
63
64        #[cfg(feature = "ILClassificationActions")]
65        #[unsafe(method(initWithClassificationAction:))]
66        #[unsafe(method_family = init)]
67        pub unsafe fn initWithClassificationAction(
68            this: Allocated<Self>,
69            action: ILClassificationAction,
70        ) -> Retained<Self>;
71
72        #[unsafe(method(init))]
73        #[unsafe(method_family = init)]
74        pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
75    );
76}
77
78/// Methods declared on superclass `NSObject`.
79impl ILClassificationResponse {
80    extern_methods!(
81        #[unsafe(method(new))]
82        #[unsafe(method_family = new)]
83        pub unsafe fn new() -> Retained<Self>;
84    );
85}