objc2_map_kit/generated/
MKMapSnapshotter.rs1use core::ffi::*;
4use core::ptr::NonNull;
5#[cfg(feature = "dispatch2")]
6use dispatch2::*;
7use objc2::__framework_prelude::*;
8use objc2_foundation::*;
9
10use crate::*;
11
12#[cfg(all(feature = "MKMapSnapshot", feature = "block2"))]
14pub type MKMapSnapshotCompletionHandler =
15 *mut block2::DynBlock<dyn Fn(*mut MKMapSnapshot, *mut NSError)>;
16
17extern_class!(
18 #[unsafe(super(NSObject))]
20 #[derive(Debug, PartialEq, Eq, Hash)]
21 pub struct MKMapSnapshotter;
22);
23
24extern_conformance!(
25 unsafe impl NSObjectProtocol for MKMapSnapshotter {}
26);
27
28impl MKMapSnapshotter {
29 extern_methods!(
30 #[cfg(feature = "MKMapSnapshotOptions")]
31 #[unsafe(method(initWithOptions:))]
32 #[unsafe(method_family = init)]
33 pub unsafe fn initWithOptions(
34 this: Allocated<Self>,
35 options: &MKMapSnapshotOptions,
36 ) -> Retained<Self>;
37
38 #[cfg(all(feature = "MKMapSnapshot", feature = "block2"))]
39 #[unsafe(method(startWithCompletionHandler:))]
40 #[unsafe(method_family = none)]
41 pub unsafe fn startWithCompletionHandler(
42 &self,
43 completion_handler: MKMapSnapshotCompletionHandler,
44 );
45
46 #[cfg(all(feature = "MKMapSnapshot", feature = "block2", feature = "dispatch2"))]
47 #[unsafe(method(startWithQueue:completionHandler:))]
48 #[unsafe(method_family = none)]
49 pub unsafe fn startWithQueue_completionHandler(
50 &self,
51 queue: &DispatchQueue,
52 completion_handler: MKMapSnapshotCompletionHandler,
53 );
54
55 #[unsafe(method(cancel))]
56 #[unsafe(method_family = none)]
57 pub unsafe fn cancel(&self);
58
59 #[unsafe(method(isLoading))]
60 #[unsafe(method_family = none)]
61 pub unsafe fn isLoading(&self) -> bool;
62 );
63}
64
65impl MKMapSnapshotter {
67 extern_methods!(
68 #[unsafe(method(init))]
69 #[unsafe(method_family = init)]
70 pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
71
72 #[unsafe(method(new))]
73 #[unsafe(method_family = new)]
74 pub unsafe fn new() -> Retained<Self>;
75 );
76}