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!(
    /// This class represents a type of HKSample that references a series of data.
    ///
    /// See also [Apple's documentation](https://developer.apple.com/documentation/healthkit/hkseriessample?language=objc)
    #[unsafe(super(HKSample, HKObject, NSObject))]
    #[derive(Debug, PartialEq, Eq, Hash)]
    #[cfg(all(feature = "HKObject", feature = "HKSample"))]
    pub struct HKSeriesSample;
);

#[cfg(all(feature = "HKObject", feature = "HKSample"))]
unsafe impl Send for HKSeriesSample {}

#[cfg(all(feature = "HKObject", feature = "HKSample"))]
unsafe impl Sync for HKSeriesSample {}

#[cfg(all(feature = "HKObject", feature = "HKSample"))]
extern_conformance!(
    unsafe impl NSCoding for HKSeriesSample {}
);

#[cfg(all(feature = "HKObject", feature = "HKSample"))]
extern_conformance!(
    unsafe impl NSObjectProtocol for HKSeriesSample {}
);

#[cfg(all(feature = "HKObject", feature = "HKSample"))]
extern_conformance!(
    unsafe impl NSSecureCoding for HKSeriesSample {}
);

#[cfg(all(feature = "HKObject", feature = "HKSample"))]
impl HKSeriesSample {
    extern_methods!(
        /// The number of individual series datum represented by the receiver and accessible
        /// through the appropriate HKQuery series subclass.
        #[unsafe(method(count))]
        #[unsafe(method_family = none)]
        pub unsafe fn count(&self) -> NSUInteger;
    );
}

/// Methods declared on superclass `HKObject`.
#[cfg(all(feature = "HKObject", feature = "HKSample"))]
impl HKSeriesSample {
    extern_methods!(
        #[unsafe(method(init))]
        #[unsafe(method_family = init)]
        pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
    );
}

/// Methods declared on superclass `NSObject`.
#[cfg(all(feature = "HKObject", feature = "HKSample"))]
impl HKSeriesSample {
    extern_methods!(
        #[unsafe(method(new))]
        #[unsafe(method_family = new)]
        pub unsafe fn new() -> Retained<Self>;
    );
}