objc2_intents/generated/
INDateComponentsRange.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::*;
5use objc2_foundation::*;
6
7use crate::*;
8
9extern_class!(
10    /// [Apple's documentation](https://developer.apple.com/documentation/intents/indatecomponentsrange?language=objc)
11    #[unsafe(super(NSObject))]
12    #[derive(Debug, PartialEq, Eq, Hash)]
13    pub struct INDateComponentsRange;
14);
15
16extern_conformance!(
17    unsafe impl NSCoding for INDateComponentsRange {}
18);
19
20extern_conformance!(
21    unsafe impl NSCopying for INDateComponentsRange {}
22);
23
24unsafe impl CopyingHelper for INDateComponentsRange {
25    type Result = Self;
26}
27
28extern_conformance!(
29    unsafe impl NSObjectProtocol for INDateComponentsRange {}
30);
31
32extern_conformance!(
33    unsafe impl NSSecureCoding for INDateComponentsRange {}
34);
35
36impl INDateComponentsRange {
37    extern_methods!(
38        #[unsafe(method(init))]
39        #[unsafe(method_family = init)]
40        pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
41
42        #[unsafe(method(initWithStartDateComponents:endDateComponents:))]
43        #[unsafe(method_family = init)]
44        pub unsafe fn initWithStartDateComponents_endDateComponents(
45            this: Allocated<Self>,
46            start_date_components: Option<&NSDateComponents>,
47            end_date_components: Option<&NSDateComponents>,
48        ) -> Retained<Self>;
49
50        #[cfg(feature = "INRecurrenceRule")]
51        #[unsafe(method(initWithStartDateComponents:endDateComponents:recurrenceRule:))]
52        #[unsafe(method_family = init)]
53        pub unsafe fn initWithStartDateComponents_endDateComponents_recurrenceRule(
54            this: Allocated<Self>,
55            start_date_components: Option<&NSDateComponents>,
56            end_date_components: Option<&NSDateComponents>,
57            recurrence_rule: Option<&INRecurrenceRule>,
58        ) -> Retained<Self>;
59
60        #[unsafe(method(startDateComponents))]
61        #[unsafe(method_family = none)]
62        pub unsafe fn startDateComponents(&self) -> Option<Retained<NSDateComponents>>;
63
64        #[unsafe(method(endDateComponents))]
65        #[unsafe(method_family = none)]
66        pub unsafe fn endDateComponents(&self) -> Option<Retained<NSDateComponents>>;
67
68        #[cfg(feature = "INRecurrenceRule")]
69        #[unsafe(method(recurrenceRule))]
70        #[unsafe(method_family = none)]
71        pub unsafe fn recurrenceRule(&self) -> Option<Retained<INRecurrenceRule>>;
72    );
73}
74
75/// Methods declared on superclass `NSObject`.
76impl INDateComponentsRange {
77    extern_methods!(
78        #[unsafe(method(new))]
79        #[unsafe(method_family = new)]
80        pub unsafe fn new() -> Retained<Self>;
81    );
82}