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
20extern_conformance!(
21 unsafe impl NSCopying for MKMapSnapshotOptions {}
22);
23
24unsafe impl CopyingHelper for MKMapSnapshotOptions {
25 type Result = Self;
26}
27
28extern_conformance!(
29 unsafe impl NSObjectProtocol for MKMapSnapshotOptions {}
30);
31
32impl MKMapSnapshotOptions {
33 extern_methods!(
34 #[cfg(feature = "MKMapConfiguration")]
35 #[unsafe(method(preferredConfiguration))]
36 #[unsafe(method_family = none)]
37 pub unsafe fn preferredConfiguration(&self) -> Retained<MKMapConfiguration>;
38
39 #[cfg(feature = "MKMapConfiguration")]
40 #[unsafe(method(setPreferredConfiguration:))]
44 #[unsafe(method_family = none)]
45 pub unsafe fn setPreferredConfiguration(
46 &self,
47 preferred_configuration: &MKMapConfiguration,
48 );
49
50 #[cfg(feature = "MKMapCamera")]
51 #[unsafe(method(camera))]
52 #[unsafe(method_family = none)]
53 pub unsafe fn camera(&self) -> Retained<MKMapCamera>;
54
55 #[cfg(feature = "MKMapCamera")]
56 #[unsafe(method(setCamera:))]
60 #[unsafe(method_family = none)]
61 pub unsafe fn setCamera(&self, camera: &MKMapCamera);
62
63 #[cfg(feature = "MKGeometry")]
64 #[unsafe(method(mapRect))]
65 #[unsafe(method_family = none)]
66 pub unsafe fn mapRect(&self) -> MKMapRect;
67
68 #[cfg(feature = "MKGeometry")]
69 #[unsafe(method(setMapRect:))]
71 #[unsafe(method_family = none)]
72 pub unsafe fn setMapRect(&self, map_rect: MKMapRect);
73
74 #[cfg(all(feature = "MKGeometry", feature = "objc2-core-location"))]
75 #[unsafe(method(region))]
76 #[unsafe(method_family = none)]
77 pub unsafe fn region(&self) -> MKCoordinateRegion;
78
79 #[cfg(all(feature = "MKGeometry", feature = "objc2-core-location"))]
80 #[unsafe(method(setRegion:))]
82 #[unsafe(method_family = none)]
83 pub unsafe fn setRegion(&self, region: MKCoordinateRegion);
84
85 #[cfg(feature = "MKTypes")]
86 #[deprecated = "Use preferredConfiguration"]
87 #[unsafe(method(mapType))]
88 #[unsafe(method_family = none)]
89 pub unsafe fn mapType(&self) -> MKMapType;
90
91 #[cfg(feature = "MKTypes")]
92 #[deprecated = "Use preferredConfiguration"]
94 #[unsafe(method(setMapType:))]
95 #[unsafe(method_family = none)]
96 pub unsafe fn setMapType(&self, map_type: MKMapType);
97
98 #[cfg(feature = "MKPointOfInterestFilter")]
99 #[deprecated = "Use preferredConfiguration"]
100 #[unsafe(method(pointOfInterestFilter))]
101 #[unsafe(method_family = none)]
102 pub unsafe fn pointOfInterestFilter(&self) -> Option<Retained<MKPointOfInterestFilter>>;
103
104 #[cfg(feature = "MKPointOfInterestFilter")]
105 #[deprecated = "Use preferredConfiguration"]
109 #[unsafe(method(setPointOfInterestFilter:))]
110 #[unsafe(method_family = none)]
111 pub unsafe fn setPointOfInterestFilter(
112 &self,
113 point_of_interest_filter: Option<&MKPointOfInterestFilter>,
114 );
115
116 #[deprecated = "Use preferredConfiguration"]
117 #[unsafe(method(showsPointsOfInterest))]
118 #[unsafe(method_family = none)]
119 pub unsafe fn showsPointsOfInterest(&self) -> bool;
120
121 #[deprecated = "Use preferredConfiguration"]
123 #[unsafe(method(setShowsPointsOfInterest:))]
124 #[unsafe(method_family = none)]
125 pub unsafe fn setShowsPointsOfInterest(&self, shows_points_of_interest: bool);
126
127 #[deprecated = "No longer supported."]
128 #[unsafe(method(showsBuildings))]
129 #[unsafe(method_family = none)]
130 pub unsafe fn showsBuildings(&self) -> bool;
131
132 #[deprecated = "No longer supported."]
134 #[unsafe(method(setShowsBuildings:))]
135 #[unsafe(method_family = none)]
136 pub unsafe fn setShowsBuildings(&self, shows_buildings: bool);
137
138 #[unsafe(method(size))]
139 #[unsafe(method_family = none)]
140 pub unsafe fn size(&self) -> NSSize;
141
142 #[unsafe(method(setSize:))]
144 #[unsafe(method_family = none)]
145 pub unsafe fn setSize(&self, size: NSSize);
146
147 #[cfg(feature = "objc2-app-kit")]
148 #[cfg(target_os = "macos")]
149 #[unsafe(method(appearance))]
150 #[unsafe(method_family = none)]
151 pub unsafe fn appearance(&self) -> Option<Retained<NSAppearance>>;
152
153 #[cfg(feature = "objc2-app-kit")]
154 #[cfg(target_os = "macos")]
155 #[unsafe(method(setAppearance:))]
157 #[unsafe(method_family = none)]
158 pub unsafe fn setAppearance(&self, appearance: Option<&NSAppearance>);
159 );
160}
161
162impl MKMapSnapshotOptions {
164 extern_methods!(
165 #[unsafe(method(init))]
166 #[unsafe(method_family = init)]
167 pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
168
169 #[unsafe(method(new))]
170 #[unsafe(method_family = new)]
171 pub unsafe fn new() -> Retained<Self>;
172 );
173}