icrate 0.1.2

Bindings to Apple's frameworks
Documentation
//! This file has been automatically generated by `objc2`'s `header-translator`.
//! DO NOT EDIT
use crate::common::*;
use crate::CoreLocation::*;
use crate::Foundation::*;
use crate::HealthKit::*;
use crate::UniformTypeIdentifiers::*;

extern_class!(
    #[derive(Debug, PartialEq, Eq, Hash)]
    #[cfg(feature = "HealthKit_HKElectrocardiogramVoltageMeasurement")]
    pub struct HKElectrocardiogramVoltageMeasurement;

    #[cfg(feature = "HealthKit_HKElectrocardiogramVoltageMeasurement")]
    unsafe impl ClassType for HKElectrocardiogramVoltageMeasurement {
        type Super = NSObject;
        type Mutability = InteriorMutable;
    }
);

#[cfg(feature = "HealthKit_HKElectrocardiogramVoltageMeasurement")]
unsafe impl NSCopying for HKElectrocardiogramVoltageMeasurement {}

#[cfg(feature = "HealthKit_HKElectrocardiogramVoltageMeasurement")]
unsafe impl NSObjectProtocol for HKElectrocardiogramVoltageMeasurement {}

extern_methods!(
    #[cfg(feature = "HealthKit_HKElectrocardiogramVoltageMeasurement")]
    unsafe impl HKElectrocardiogramVoltageMeasurement {
        #[method(timeSinceSampleStart)]
        pub unsafe fn timeSinceSampleStart(&self) -> NSTimeInterval;

        #[cfg(feature = "HealthKit_HKQuantity")]
        #[method_id(@__retain_semantics Other quantityForLead:)]
        pub unsafe fn quantityForLead(
            &self,
            lead: HKElectrocardiogramLead,
        ) -> Option<Id<HKQuantity>>;
    }
);

extern_methods!(
    /// Methods declared on superclass `NSObject`
    #[cfg(feature = "HealthKit_HKElectrocardiogramVoltageMeasurement")]
    unsafe impl HKElectrocardiogramVoltageMeasurement {
        #[method_id(@__retain_semantics Init init)]
        pub unsafe fn init(this: Allocated<Self>) -> Id<Self>;

        #[method_id(@__retain_semantics New new)]
        pub unsafe fn new() -> Id<Self>;
    }
);

extern_class!(
    #[derive(Debug, PartialEq, Eq, Hash)]
    #[cfg(feature = "HealthKit_HKElectrocardiogramQuery")]
    pub struct HKElectrocardiogramQuery;

    #[cfg(feature = "HealthKit_HKElectrocardiogramQuery")]
    unsafe impl ClassType for HKElectrocardiogramQuery {
        #[inherits(NSObject)]
        type Super = HKQuery;
        type Mutability = InteriorMutable;
    }
);

#[cfg(feature = "HealthKit_HKElectrocardiogramQuery")]
unsafe impl NSObjectProtocol for HKElectrocardiogramQuery {}

extern_methods!(
    #[cfg(feature = "HealthKit_HKElectrocardiogramQuery")]
    unsafe impl HKElectrocardiogramQuery {
        #[cfg(all(
            feature = "Foundation_NSError",
            feature = "HealthKit_HKElectrocardiogram",
            feature = "HealthKit_HKElectrocardiogramVoltageMeasurement"
        ))]
        #[method_id(@__retain_semantics Init initWithElectrocardiogram:dataHandler:)]
        pub unsafe fn initWithElectrocardiogram_dataHandler(
            this: Allocated<Self>,
            electrocardiogram: &HKElectrocardiogram,
            data_handler: &Block<
                (
                    NonNull<HKElectrocardiogramQuery>,
                    *mut HKElectrocardiogramVoltageMeasurement,
                    Bool,
                    *mut NSError,
                ),
                (),
            >,
        ) -> Id<Self>;
    }
);

extern_methods!(
    /// Methods declared on superclass `HKQuery`
    #[cfg(feature = "HealthKit_HKElectrocardiogramQuery")]
    unsafe impl HKElectrocardiogramQuery {
        #[method_id(@__retain_semantics Init init)]
        pub unsafe fn init(this: Allocated<Self>) -> Id<Self>;
    }
);

extern_methods!(
    /// Methods declared on superclass `NSObject`
    #[cfg(feature = "HealthKit_HKElectrocardiogramQuery")]
    unsafe impl HKElectrocardiogramQuery {
        #[method_id(@__retain_semantics New new)]
        pub unsafe fn new() -> Id<Self>;
    }
);