objc2_intents/generated/
INRentalCarReservation.rs

1//! This file has been automatically generated by `objc2`'s `header-translator`.
2//! DO NOT EDIT
3use core::ptr::NonNull;
4use objc2::__framework_prelude::*;
5#[cfg(feature = "objc2-core-location")]
6use objc2_core_location::*;
7use objc2_foundation::*;
8
9use crate::*;
10
11extern_class!(
12    /// [Apple's documentation](https://developer.apple.com/documentation/intents/inrentalcarreservation?language=objc)
13    #[unsafe(super(INReservation, NSObject))]
14    #[derive(Debug, PartialEq, Eq, Hash)]
15    #[cfg(feature = "INReservation")]
16    pub struct INRentalCarReservation;
17);
18
19#[cfg(feature = "INReservation")]
20extern_conformance!(
21    unsafe impl NSCoding for INRentalCarReservation {}
22);
23
24#[cfg(feature = "INReservation")]
25extern_conformance!(
26    unsafe impl NSCopying for INRentalCarReservation {}
27);
28
29#[cfg(feature = "INReservation")]
30unsafe impl CopyingHelper for INRentalCarReservation {
31    type Result = Self;
32}
33
34#[cfg(feature = "INReservation")]
35extern_conformance!(
36    unsafe impl NSObjectProtocol for INRentalCarReservation {}
37);
38
39#[cfg(feature = "INReservation")]
40extern_conformance!(
41    unsafe impl NSSecureCoding for INRentalCarReservation {}
42);
43
44#[cfg(feature = "INReservation")]
45impl INRentalCarReservation {
46    extern_methods!(
47        #[cfg(all(
48            feature = "INDateComponentsRange",
49            feature = "INRentalCar",
50            feature = "INReservationAction",
51            feature = "INReservationStatus",
52            feature = "INSpeakableString",
53            feature = "objc2-core-location"
54        ))]
55        #[unsafe(method(initWithItemReference:reservationNumber:bookingTime:reservationStatus:reservationHolderName:actions:URL:rentalCar:rentalDuration:pickupLocation:dropOffLocation:))]
56        #[unsafe(method_family = init)]
57        pub unsafe fn initWithItemReference_reservationNumber_bookingTime_reservationStatus_reservationHolderName_actions_URL_rentalCar_rentalDuration_pickupLocation_dropOffLocation(
58            this: Allocated<Self>,
59            item_reference: &INSpeakableString,
60            reservation_number: Option<&NSString>,
61            booking_time: Option<&NSDate>,
62            reservation_status: INReservationStatus,
63            reservation_holder_name: Option<&NSString>,
64            actions: Option<&NSArray<INReservationAction>>,
65            url: Option<&NSURL>,
66            rental_car: &INRentalCar,
67            rental_duration: &INDateComponentsRange,
68            pickup_location: Option<&CLPlacemark>,
69            drop_off_location: Option<&CLPlacemark>,
70        ) -> Retained<Self>;
71
72        #[cfg(all(
73            feature = "INDateComponentsRange",
74            feature = "INRentalCar",
75            feature = "INReservationAction",
76            feature = "INReservationStatus",
77            feature = "INSpeakableString",
78            feature = "objc2-core-location"
79        ))]
80        #[unsafe(method(initWithItemReference:reservationNumber:bookingTime:reservationStatus:reservationHolderName:actions:rentalCar:rentalDuration:pickupLocation:dropOffLocation:))]
81        #[unsafe(method_family = init)]
82        pub unsafe fn initWithItemReference_reservationNumber_bookingTime_reservationStatus_reservationHolderName_actions_rentalCar_rentalDuration_pickupLocation_dropOffLocation(
83            this: Allocated<Self>,
84            item_reference: &INSpeakableString,
85            reservation_number: Option<&NSString>,
86            booking_time: Option<&NSDate>,
87            reservation_status: INReservationStatus,
88            reservation_holder_name: Option<&NSString>,
89            actions: Option<&NSArray<INReservationAction>>,
90            rental_car: &INRentalCar,
91            rental_duration: &INDateComponentsRange,
92            pickup_location: Option<&CLPlacemark>,
93            drop_off_location: Option<&CLPlacemark>,
94        ) -> Retained<Self>;
95
96        #[cfg(feature = "INRentalCar")]
97        #[unsafe(method(rentalCar))]
98        #[unsafe(method_family = none)]
99        pub unsafe fn rentalCar(&self) -> Retained<INRentalCar>;
100
101        #[cfg(feature = "INDateComponentsRange")]
102        #[unsafe(method(rentalDuration))]
103        #[unsafe(method_family = none)]
104        pub unsafe fn rentalDuration(&self) -> Retained<INDateComponentsRange>;
105
106        #[cfg(feature = "objc2-core-location")]
107        #[unsafe(method(pickupLocation))]
108        #[unsafe(method_family = none)]
109        pub unsafe fn pickupLocation(&self) -> Option<Retained<CLPlacemark>>;
110
111        #[cfg(feature = "objc2-core-location")]
112        #[unsafe(method(dropOffLocation))]
113        #[unsafe(method_family = none)]
114        pub unsafe fn dropOffLocation(&self) -> Option<Retained<CLPlacemark>>;
115    );
116}
117
118/// Methods declared on superclass `INReservation`.
119#[cfg(feature = "INReservation")]
120impl INRentalCarReservation {
121    extern_methods!(
122        #[unsafe(method(init))]
123        #[unsafe(method_family = init)]
124        pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
125    );
126}
127
128/// Methods declared on superclass `NSObject`.
129#[cfg(feature = "INReservation")]
130impl INRentalCarReservation {
131    extern_methods!(
132        #[unsafe(method(new))]
133        #[unsafe(method_family = new)]
134        pub unsafe fn new() -> Retained<Self>;
135    );
136}