objc2-core-location 0.3.2

Bindings to the CoreLocation 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!(
    /// [Apple's documentation](https://developer.apple.com/documentation/corelocation/clcircularregion?language=objc)
    #[unsafe(super(CLRegion, NSObject))]
    #[derive(Debug, PartialEq, Eq, Hash)]
    #[cfg(feature = "CLRegion")]
    #[deprecated]
    pub struct CLCircularRegion;
);

#[cfg(feature = "CLRegion")]
extern_conformance!(
    unsafe impl NSCoding for CLCircularRegion {}
);

#[cfg(feature = "CLRegion")]
extern_conformance!(
    unsafe impl NSCopying for CLCircularRegion {}
);

#[cfg(feature = "CLRegion")]
unsafe impl CopyingHelper for CLCircularRegion {
    type Result = Self;
}

#[cfg(feature = "CLRegion")]
extern_conformance!(
    unsafe impl NSObjectProtocol for CLCircularRegion {}
);

#[cfg(feature = "CLRegion")]
extern_conformance!(
    unsafe impl NSSecureCoding for CLCircularRegion {}
);

#[cfg(feature = "CLRegion")]
impl CLCircularRegion {
    extern_methods!(
        #[cfg(feature = "CLLocation")]
        #[deprecated]
        #[unsafe(method(initWithCenter:radius:identifier:))]
        #[unsafe(method_family = init)]
        pub unsafe fn initWithCenter_radius_identifier(
            this: Allocated<Self>,
            center: CLLocationCoordinate2D,
            radius: CLLocationDistance,
            identifier: &NSString,
        ) -> Retained<Self>;

        #[cfg(feature = "CLLocation")]
        #[deprecated]
        #[unsafe(method(center))]
        #[unsafe(method_family = none)]
        pub unsafe fn center(&self) -> CLLocationCoordinate2D;

        #[cfg(feature = "CLLocation")]
        #[deprecated]
        #[unsafe(method(radius))]
        #[unsafe(method_family = none)]
        pub unsafe fn radius(&self) -> CLLocationDistance;

        #[cfg(feature = "CLLocation")]
        #[deprecated]
        #[unsafe(method(containsCoordinate:))]
        #[unsafe(method_family = none)]
        pub unsafe fn containsCoordinate(&self, coordinate: CLLocationCoordinate2D) -> bool;
    );
}

/// Methods declared on superclass `CLRegion`.
#[cfg(feature = "CLRegion")]
impl CLCircularRegion {
    extern_methods!(
        #[cfg(feature = "CLLocation")]
        #[deprecated = "Please see CLCircularRegion"]
        #[unsafe(method(initCircularRegionWithCenter:radius:identifier:))]
        #[unsafe(method_family = init)]
        pub unsafe fn initCircularRegionWithCenter_radius_identifier(
            this: Allocated<Self>,
            center: CLLocationCoordinate2D,
            radius: CLLocationDistance,
            identifier: &NSString,
        ) -> Retained<Self>;
    );
}

/// Methods declared on superclass `NSObject`.
#[cfg(feature = "CLRegion")]
impl CLCircularRegion {
    extern_methods!(
        #[unsafe(method(init))]
        #[unsafe(method_family = init)]
        pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;

        #[unsafe(method(new))]
        #[unsafe(method_family = new)]
        pub unsafe fn new() -> Retained<Self>;
    );
}