objc2-health-kit 0.3.2

Bindings to the HealthKit framework
Documentation
//! This file has been automatically generated by `objc2`'s `header-translator`.
//! DO NOT EDIT
use core::ptr::NonNull;
use objc2::__framework_prelude::*;
use objc2_foundation::*;

use crate::*;

extern_class!(
    /// A class representing an HKObject that was deleted from the HealtKit database.
    ///
    /// See also [Apple's documentation](https://developer.apple.com/documentation/healthkit/hkdeletedobject?language=objc)
    #[unsafe(super(NSObject))]
    #[derive(Debug, PartialEq, Eq, Hash)]
    pub struct HKDeletedObject;
);

unsafe impl Send for HKDeletedObject {}

unsafe impl Sync for HKDeletedObject {}

extern_conformance!(
    unsafe impl NSCoding for HKDeletedObject {}
);

extern_conformance!(
    unsafe impl NSObjectProtocol for HKDeletedObject {}
);

extern_conformance!(
    unsafe impl NSSecureCoding for HKDeletedObject {}
);

impl HKDeletedObject {
    extern_methods!(
        /// The unique identifier of the HKObject that was deleted from the HealthKit database.
        #[unsafe(method(UUID))]
        #[unsafe(method_family = none)]
        pub unsafe fn UUID(&self) -> Retained<NSUUID>;

        /// Extra information describing properties of the receiver.
        ///
        /// Metadata retained from the deleted HKObject.
        /// Available keys: HKMetadataKeySyncIdentifier, HKMetadataKeySyncVersion
        #[unsafe(method(metadata))]
        #[unsafe(method_family = none)]
        pub unsafe fn metadata(&self) -> Option<Retained<NSDictionary<NSString, AnyObject>>>;

        #[unsafe(method(init))]
        #[unsafe(method_family = init)]
        pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
    );
}

/// Methods declared on superclass `NSObject`.
impl HKDeletedObject {
    extern_methods!(
        #[unsafe(method(new))]
        #[unsafe(method_family = new)]
        pub unsafe fn new() -> Retained<Self>;
    );
}