objc2_health_kit/generated/
HKContactsPrescription.rs1use core::ptr::NonNull;
4use objc2::__framework_prelude::*;
5use objc2_foundation::*;
6
7use crate::*;
8
9extern_class!(
10 #[unsafe(super(HKVisionPrescription, HKSample, HKObject, NSObject))]
14 #[derive(Debug, PartialEq, Eq, Hash)]
15 #[cfg(all(
16 feature = "HKObject",
17 feature = "HKSample",
18 feature = "HKVisionPrescription"
19 ))]
20 pub struct HKContactsPrescription;
21);
22
23#[cfg(all(
24 feature = "HKObject",
25 feature = "HKSample",
26 feature = "HKVisionPrescription"
27))]
28unsafe impl Send for HKContactsPrescription {}
29
30#[cfg(all(
31 feature = "HKObject",
32 feature = "HKSample",
33 feature = "HKVisionPrescription"
34))]
35unsafe impl Sync for HKContactsPrescription {}
36
37#[cfg(all(
38 feature = "HKObject",
39 feature = "HKSample",
40 feature = "HKVisionPrescription"
41))]
42extern_conformance!(
43 unsafe impl NSCoding for HKContactsPrescription {}
44);
45
46#[cfg(all(
47 feature = "HKObject",
48 feature = "HKSample",
49 feature = "HKVisionPrescription"
50))]
51extern_conformance!(
52 unsafe impl NSCopying for HKContactsPrescription {}
53);
54
55#[cfg(all(
56 feature = "HKObject",
57 feature = "HKSample",
58 feature = "HKVisionPrescription"
59))]
60unsafe impl CopyingHelper for HKContactsPrescription {
61 type Result = Self;
62}
63
64#[cfg(all(
65 feature = "HKObject",
66 feature = "HKSample",
67 feature = "HKVisionPrescription"
68))]
69extern_conformance!(
70 unsafe impl NSObjectProtocol for HKContactsPrescription {}
71);
72
73#[cfg(all(
74 feature = "HKObject",
75 feature = "HKSample",
76 feature = "HKVisionPrescription"
77))]
78extern_conformance!(
79 unsafe impl NSSecureCoding for HKContactsPrescription {}
80);
81
82#[cfg(all(
83 feature = "HKObject",
84 feature = "HKSample",
85 feature = "HKVisionPrescription"
86))]
87impl HKContactsPrescription {
88 extern_methods!(
89 #[cfg(all(
90 feature = "HKContactsLensSpecification",
91 feature = "HKLensSpecification"
92 ))]
93 #[unsafe(method(rightEye))]
101 #[unsafe(method_family = none)]
102 pub unsafe fn rightEye(&self) -> Option<Retained<HKContactsLensSpecification>>;
103
104 #[cfg(all(
105 feature = "HKContactsLensSpecification",
106 feature = "HKLensSpecification"
107 ))]
108 #[unsafe(method(leftEye))]
116 #[unsafe(method_family = none)]
117 pub unsafe fn leftEye(&self) -> Option<Retained<HKContactsLensSpecification>>;
118
119 #[unsafe(method(brand))]
127 #[unsafe(method_family = none)]
128 pub unsafe fn brand(&self) -> Retained<NSString>;
129
130 #[cfg(all(
131 feature = "HKContactsLensSpecification",
132 feature = "HKDevice",
133 feature = "HKLensSpecification"
134 ))]
135 #[unsafe(method(prescriptionWithRightEyeSpecification:leftEyeSpecification:brand:dateIssued:expirationDate:device:metadata:))]
153 #[unsafe(method_family = none)]
154 pub unsafe fn prescriptionWithRightEyeSpecification_leftEyeSpecification_brand_dateIssued_expirationDate_device_metadata(
155 right_eye_specification: Option<&HKContactsLensSpecification>,
156 left_eye_specification: Option<&HKContactsLensSpecification>,
157 brand: &NSString,
158 date_issued: &NSDate,
159 expiration_date: Option<&NSDate>,
160 device: Option<&HKDevice>,
161 metadata: Option<&NSDictionary<NSString, AnyObject>>,
162 ) -> Retained<Self>;
163
164 #[unsafe(method(init))]
165 #[unsafe(method_family = init)]
166 pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
167
168 #[unsafe(method(new))]
169 #[unsafe(method_family = new)]
170 pub unsafe fn new() -> Retained<Self>;
171
172 #[cfg(feature = "HKDevice")]
173 #[unsafe(method(prescriptionWithType:dateIssued:expirationDate:device:metadata:))]
177 #[unsafe(method_family = none)]
178 pub unsafe fn prescriptionWithType_dateIssued_expirationDate_device_metadata(
179 r#type: HKVisionPrescriptionType,
180 date_issued: &NSDate,
181 expiration_date: Option<&NSDate>,
182 device: Option<&HKDevice>,
183 metadata: Option<&NSDictionary<NSString, AnyObject>>,
184 ) -> Retained<Self>;
185 );
186}