use core::ptr::NonNull;
use objc2::__framework_prelude::*;
#[cfg(feature = "objc2-core-location")]
use objc2_core_location::*;
use objc2_foundation::*;
use crate::*;
extern_class!(
#[unsafe(super(MKMultiPoint, MKShape, NSObject))]
#[derive(Debug, PartialEq, Eq, Hash)]
#[cfg(all(feature = "MKMultiPoint", feature = "MKShape"))]
pub struct MKPolygon;
);
#[cfg(all(
feature = "MKAnnotation",
feature = "MKMultiPoint",
feature = "MKShape"
))]
extern_conformance!(
unsafe impl MKAnnotation for MKPolygon {}
);
#[cfg(all(
feature = "MKAnnotation",
feature = "MKMultiPoint",
feature = "MKOverlay",
feature = "MKShape"
))]
extern_conformance!(
unsafe impl MKOverlay for MKPolygon {}
);
#[cfg(all(feature = "MKMultiPoint", feature = "MKShape"))]
extern_conformance!(
unsafe impl NSObjectProtocol for MKPolygon {}
);
#[cfg(all(feature = "MKMultiPoint", feature = "MKShape"))]
impl MKPolygon {
extern_methods!(
#[cfg(feature = "MKGeometry")]
#[unsafe(method(polygonWithPoints:count:))]
#[unsafe(method_family = none)]
pub unsafe fn polygonWithPoints_count(
points: NonNull<MKMapPoint>,
count: NSUInteger,
) -> Retained<Self>;
#[cfg(feature = "MKGeometry")]
#[unsafe(method(polygonWithPoints:count:interiorPolygons:))]
#[unsafe(method_family = none)]
pub unsafe fn polygonWithPoints_count_interiorPolygons(
points: NonNull<MKMapPoint>,
count: NSUInteger,
interior_polygons: Option<&NSArray<MKPolygon>>,
) -> Retained<Self>;
#[cfg(feature = "objc2-core-location")]
#[unsafe(method(polygonWithCoordinates:count:))]
#[unsafe(method_family = none)]
pub unsafe fn polygonWithCoordinates_count(
coords: NonNull<CLLocationCoordinate2D>,
count: NSUInteger,
) -> Retained<Self>;
#[cfg(feature = "objc2-core-location")]
#[unsafe(method(polygonWithCoordinates:count:interiorPolygons:))]
#[unsafe(method_family = none)]
pub unsafe fn polygonWithCoordinates_count_interiorPolygons(
coords: NonNull<CLLocationCoordinate2D>,
count: NSUInteger,
interior_polygons: Option<&NSArray<MKPolygon>>,
) -> Retained<Self>;
#[unsafe(method(interiorPolygons))]
#[unsafe(method_family = none)]
pub unsafe fn interiorPolygons(&self) -> Option<Retained<NSArray<MKPolygon>>>;
);
}
#[cfg(all(feature = "MKMultiPoint", feature = "MKShape"))]
impl MKPolygon {
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>;
);
}