objc2_map_kit/generated/
MKMapSnapshotOptions.rs1use core::ffi::*;
4use core::ptr::NonNull;
5use objc2::__framework_prelude::*;
6#[cfg(feature = "objc2-app-kit")]
7#[cfg(target_os = "macos")]
8use objc2_app_kit::*;
9use objc2_foundation::*;
10
11use crate::*;
12
13extern_class!(
14 #[unsafe(super(NSObject))]
16 #[derive(Debug, PartialEq, Eq, Hash)]
17 pub struct MKMapSnapshotOptions;
18);
19
20unsafe impl NSCopying for MKMapSnapshotOptions {}
21
22unsafe impl CopyingHelper for MKMapSnapshotOptions {
23 type Result = Self;
24}
25
26unsafe impl NSObjectProtocol for MKMapSnapshotOptions {}
27
28impl MKMapSnapshotOptions {
29 extern_methods!(
30 #[cfg(feature = "MKMapConfiguration")]
31 #[unsafe(method(preferredConfiguration))]
32 #[unsafe(method_family = none)]
33 pub unsafe fn preferredConfiguration(&self) -> Retained<MKMapConfiguration>;
34
35 #[cfg(feature = "MKMapConfiguration")]
36 #[unsafe(method(setPreferredConfiguration:))]
38 #[unsafe(method_family = none)]
39 pub unsafe fn setPreferredConfiguration(
40 &self,
41 preferred_configuration: &MKMapConfiguration,
42 );
43
44 #[cfg(feature = "MKMapCamera")]
45 #[unsafe(method(camera))]
46 #[unsafe(method_family = none)]
47 pub unsafe fn camera(&self) -> Retained<MKMapCamera>;
48
49 #[cfg(feature = "MKMapCamera")]
50 #[unsafe(method(setCamera:))]
52 #[unsafe(method_family = none)]
53 pub unsafe fn setCamera(&self, camera: &MKMapCamera);
54
55 #[cfg(feature = "MKGeometry")]
56 #[unsafe(method(mapRect))]
57 #[unsafe(method_family = none)]
58 pub unsafe fn mapRect(&self) -> MKMapRect;
59
60 #[cfg(feature = "MKGeometry")]
61 #[unsafe(method(setMapRect:))]
63 #[unsafe(method_family = none)]
64 pub unsafe fn setMapRect(&self, map_rect: MKMapRect);
65
66 #[cfg(all(feature = "MKGeometry", feature = "objc2-core-location"))]
67 #[unsafe(method(region))]
68 #[unsafe(method_family = none)]
69 pub unsafe fn region(&self) -> MKCoordinateRegion;
70
71 #[cfg(all(feature = "MKGeometry", feature = "objc2-core-location"))]
72 #[unsafe(method(setRegion:))]
74 #[unsafe(method_family = none)]
75 pub unsafe fn setRegion(&self, region: MKCoordinateRegion);
76
77 #[cfg(feature = "MKTypes")]
78 #[deprecated = "Use preferredConfiguration"]
79 #[unsafe(method(mapType))]
80 #[unsafe(method_family = none)]
81 pub unsafe fn mapType(&self) -> MKMapType;
82
83 #[cfg(feature = "MKTypes")]
84 #[deprecated = "Use preferredConfiguration"]
86 #[unsafe(method(setMapType:))]
87 #[unsafe(method_family = none)]
88 pub unsafe fn setMapType(&self, map_type: MKMapType);
89
90 #[cfg(feature = "MKPointOfInterestFilter")]
91 #[deprecated = "Use preferredConfiguration"]
92 #[unsafe(method(pointOfInterestFilter))]
93 #[unsafe(method_family = none)]
94 pub unsafe fn pointOfInterestFilter(&self) -> Option<Retained<MKPointOfInterestFilter>>;
95
96 #[cfg(feature = "MKPointOfInterestFilter")]
97 #[deprecated = "Use preferredConfiguration"]
99 #[unsafe(method(setPointOfInterestFilter:))]
100 #[unsafe(method_family = none)]
101 pub unsafe fn setPointOfInterestFilter(
102 &self,
103 point_of_interest_filter: Option<&MKPointOfInterestFilter>,
104 );
105
106 #[deprecated = "Use preferredConfiguration"]
107 #[unsafe(method(showsPointsOfInterest))]
108 #[unsafe(method_family = none)]
109 pub unsafe fn showsPointsOfInterest(&self) -> bool;
110
111 #[deprecated = "Use preferredConfiguration"]
113 #[unsafe(method(setShowsPointsOfInterest:))]
114 #[unsafe(method_family = none)]
115 pub unsafe fn setShowsPointsOfInterest(&self, shows_points_of_interest: bool);
116
117 #[deprecated = "No longer supported."]
118 #[unsafe(method(showsBuildings))]
119 #[unsafe(method_family = none)]
120 pub unsafe fn showsBuildings(&self) -> bool;
121
122 #[deprecated = "No longer supported."]
124 #[unsafe(method(setShowsBuildings:))]
125 #[unsafe(method_family = none)]
126 pub unsafe fn setShowsBuildings(&self, shows_buildings: bool);
127
128 #[unsafe(method(size))]
129 #[unsafe(method_family = none)]
130 pub unsafe fn size(&self) -> NSSize;
131
132 #[unsafe(method(setSize:))]
134 #[unsafe(method_family = none)]
135 pub unsafe fn setSize(&self, size: NSSize);
136
137 #[cfg(feature = "objc2-app-kit")]
138 #[cfg(target_os = "macos")]
139 #[unsafe(method(appearance))]
140 #[unsafe(method_family = none)]
141 pub unsafe fn appearance(&self) -> Option<Retained<NSAppearance>>;
142
143 #[cfg(feature = "objc2-app-kit")]
144 #[cfg(target_os = "macos")]
145 #[unsafe(method(setAppearance:))]
147 #[unsafe(method_family = none)]
148 pub unsafe fn setAppearance(&self, appearance: Option<&NSAppearance>);
149 );
150}
151
152impl MKMapSnapshotOptions {
154 extern_methods!(
155 #[unsafe(method(init))]
156 #[unsafe(method_family = init)]
157 pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
158
159 #[unsafe(method(new))]
160 #[unsafe(method_family = new)]
161 pub unsafe fn new() -> Retained<Self>;
162 );
163}