objc2_core_motion/generated/
CMAltitude.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/coremotion/cmaltitudedata?language=objc)
11    #[unsafe(super(CMLogItem, NSObject))]
12    #[derive(Debug, PartialEq, Eq, Hash)]
13    #[cfg(feature = "CMLogItem")]
14    pub struct CMAltitudeData;
15);
16
17#[cfg(feature = "CMLogItem")]
18extern_conformance!(
19    unsafe impl NSCoding for CMAltitudeData {}
20);
21
22#[cfg(feature = "CMLogItem")]
23extern_conformance!(
24    unsafe impl NSCopying for CMAltitudeData {}
25);
26
27#[cfg(feature = "CMLogItem")]
28unsafe impl CopyingHelper for CMAltitudeData {
29    type Result = Self;
30}
31
32#[cfg(feature = "CMLogItem")]
33extern_conformance!(
34    unsafe impl NSObjectProtocol for CMAltitudeData {}
35);
36
37#[cfg(feature = "CMLogItem")]
38extern_conformance!(
39    unsafe impl NSSecureCoding for CMAltitudeData {}
40);
41
42#[cfg(feature = "CMLogItem")]
43impl CMAltitudeData {
44    extern_methods!(
45        #[unsafe(method(relativeAltitude))]
46        #[unsafe(method_family = none)]
47        pub unsafe fn relativeAltitude(&self) -> Retained<NSNumber>;
48
49        #[unsafe(method(pressure))]
50        #[unsafe(method_family = none)]
51        pub unsafe fn pressure(&self) -> Retained<NSNumber>;
52    );
53}
54
55/// Methods declared on superclass `NSObject`.
56#[cfg(feature = "CMLogItem")]
57impl CMAltitudeData {
58    extern_methods!(
59        #[unsafe(method(init))]
60        #[unsafe(method_family = init)]
61        pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
62
63        #[unsafe(method(new))]
64        #[unsafe(method_family = new)]
65        pub unsafe fn new() -> Retained<Self>;
66    );
67}