objc2_intents/generated/
INGetRestaurantGuestIntent.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    /// [Apple's documentation](https://developer.apple.com/documentation/intents/ingetrestaurantguestintent?language=objc)
12    #[unsafe(super(INIntent, NSObject))]
13    #[derive(Debug, PartialEq, Eq, Hash)]
14    #[cfg(feature = "INIntent")]
15    pub struct INGetRestaurantGuestIntent;
16);
17
18#[cfg(feature = "INIntent")]
19extern_conformance!(
20    unsafe impl NSCoding for INGetRestaurantGuestIntent {}
21);
22
23#[cfg(feature = "INIntent")]
24extern_conformance!(
25    unsafe impl NSCopying for INGetRestaurantGuestIntent {}
26);
27
28#[cfg(feature = "INIntent")]
29unsafe impl CopyingHelper for INGetRestaurantGuestIntent {
30    type Result = Self;
31}
32
33#[cfg(feature = "INIntent")]
34extern_conformance!(
35    unsafe impl NSObjectProtocol for INGetRestaurantGuestIntent {}
36);
37
38#[cfg(feature = "INIntent")]
39extern_conformance!(
40    unsafe impl NSSecureCoding for INGetRestaurantGuestIntent {}
41);
42
43#[cfg(feature = "INIntent")]
44impl INGetRestaurantGuestIntent {
45    extern_methods!();
46}
47
48/// Methods declared on superclass `NSObject`.
49#[cfg(feature = "INIntent")]
50impl INGetRestaurantGuestIntent {
51    extern_methods!(
52        #[unsafe(method(init))]
53        #[unsafe(method_family = init)]
54        pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
55
56        #[unsafe(method(new))]
57        #[unsafe(method_family = new)]
58        pub unsafe fn new() -> Retained<Self>;
59    );
60}
61
62extern_protocol!(
63    /// [Apple's documentation](https://developer.apple.com/documentation/intents/ingetrestaurantguestintenthandling?language=objc)
64    pub unsafe trait INGetRestaurantGuestIntentHandling: NSObjectProtocol {
65        #[cfg(all(
66            feature = "INGetRestaurantGuestIntentResponse",
67            feature = "INIntent",
68            feature = "INIntentResponse",
69            feature = "block2"
70        ))]
71        /// Handling method - Execute the task represented by the INGetRestaurantGuestIntent that's passed in
72        ///
73        /// This method is called to actually execute the intent, the app must return a response for this intent and an NSUserActivity capturing the state that the app must be restored to at the end of handling this intent
74        ///
75        ///
76        /// Parameter `intent`: The input intent
77        ///
78        /// Parameter `completion`: The response handling block to invoke with the response to handling the intent.
79        ///
80        ///
81        /// See: INGetRestaurantGuestIntentResponse
82        #[unsafe(method(handleGetRestaurantGuest:completion:))]
83        #[unsafe(method_family = none)]
84        unsafe fn handleGetRestaurantGuest_completion(
85            &self,
86            intent: &INGetRestaurantGuestIntent,
87            completion: &block2::DynBlock<dyn Fn(NonNull<INGetRestaurantGuestIntentResponse>)>,
88        );
89
90        #[cfg(all(
91            feature = "INGetRestaurantGuestIntentResponse",
92            feature = "INIntent",
93            feature = "INIntentResponse",
94            feature = "block2"
95        ))]
96        /// Confirmation method - Validate that this intent is ready for the next step (i.e. handling)
97        ///
98        /// These methods are called prior to asking the app to handle the intent. The app should return a response object that contains additional information about the intent, which may be relevant for the system to show the user prior to handling. If unimplemented, the system will assume the intent is valid following resolution, and will assume there is no additional information relevant to this intent.
99        ///
100        ///
101        /// Parameter `guestIntent`: The input intent
102        ///
103        /// Parameter `completion`: The response block contains an INGetRestaurantGuestIntentResponse containing additional details about the intent that may be relevant for the system to show the user prior to handling.
104        ///
105        ///
106        /// See: INGetRestaurantGuestIntentResponse
107        #[optional]
108        #[unsafe(method(confirmGetRestaurantGuest:completion:))]
109        #[unsafe(method_family = none)]
110        unsafe fn confirmGetRestaurantGuest_completion(
111            &self,
112            guest_intent: &INGetRestaurantGuestIntent,
113            completion: &block2::DynBlock<dyn Fn(NonNull<INGetRestaurantGuestIntentResponse>)>,
114        );
115    }
116);