objc2_health_kit/generated/
HKObject.rs1use core::ptr::NonNull;
4use objc2::__framework_prelude::*;
5use objc2_foundation::*;
6
7use crate::*;
8
9extern_class!(
10 #[unsafe(super(NSObject))]
12 #[derive(Debug, PartialEq, Eq, Hash)]
13 pub struct HKObject;
14);
15
16unsafe impl Send for HKObject {}
17
18unsafe impl Sync for HKObject {}
19
20extern_conformance!(
21 unsafe impl NSCoding for HKObject {}
22);
23
24extern_conformance!(
25 unsafe impl NSObjectProtocol for HKObject {}
26);
27
28extern_conformance!(
29 unsafe impl NSSecureCoding for HKObject {}
30);
31
32impl HKObject {
33 extern_methods!(
34 #[unsafe(method(UUID))]
36 #[unsafe(method_family = none)]
37 pub unsafe fn UUID(&self) -> Retained<NSUUID>;
38
39 #[cfg(feature = "HKSource")]
40 #[deprecated]
41 #[unsafe(method(source))]
42 #[unsafe(method_family = none)]
43 pub unsafe fn source(&self) -> Retained<HKSource>;
44
45 #[cfg(feature = "HKSourceRevision")]
46 #[unsafe(method(sourceRevision))]
48 #[unsafe(method_family = none)]
49 pub unsafe fn sourceRevision(&self) -> Retained<HKSourceRevision>;
50
51 #[cfg(feature = "HKDevice")]
52 #[unsafe(method(device))]
54 #[unsafe(method_family = none)]
55 pub unsafe fn device(&self) -> Option<Retained<HKDevice>>;
56
57 #[unsafe(method(metadata))]
62 #[unsafe(method_family = none)]
63 pub unsafe fn metadata(&self) -> Option<Retained<NSDictionary<NSString, AnyObject>>>;
64
65 #[unsafe(method(init))]
66 #[unsafe(method_family = init)]
67 pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
68 );
69}
70
71impl HKObject {
73 extern_methods!(
74 #[unsafe(method(new))]
75 #[unsafe(method_family = new)]
76 pub unsafe fn new() -> Retained<Self>;
77 );
78}
79
80extern "C" {
81 pub static HKPredicateKeyPathUUID: &'static NSString;
83}
84
85extern "C" {
86 pub static HKPredicateKeyPathSource: &'static NSString;
88}
89
90extern "C" {
91 pub static HKPredicateKeyPathMetadata: &'static NSString;
93}
94
95extern "C" {
96 pub static HKPredicateKeyPathCorrelation: &'static NSString;
98}
99
100extern "C" {
101 pub static HKPredicateKeyPathWorkout: &'static NSString;
103}
104
105extern "C" {
106 pub static HKPredicateKeyPathDevice: &'static NSString;
108}
109
110extern "C" {
111 pub static HKPredicateKeyPathSourceRevision: &'static NSString;
113}
114
115extern "C" {
116 pub static HKPredicateKeyPathWorkoutEffortRelationship: &'static NSString;
118}