This repository was archived by the owner on May 1, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 173
/
Copy pathApiDefinition.cs
1509 lines (1120 loc) · 43.6 KB
/
ApiDefinition.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
using System;
using ObjCRuntime;
using Foundation;
using UIKit;
using CoreLocation;
using CoreAnimation;
using CoreGraphics;
#if !NET
using NativeHandle = System.IntPtr;
#endif
namespace Google.Maps
{
#region CustomLib
// This is a custom class created by me (dalexsoto) and is not part of Google Maps lib
// But it is necesary for this binding to work
[Static]
interface Constants
{
[Field ("kGMSLayerCameraLatitudeKey", "__Internal")]
NSString LayerCameraLatitudeKey { get; }
[Field ("kGMSLayerCameraLongitudeKey", "__Internal")]
NSString LayerCameraLongitudeKey { get; }
[Field ("kGMSLayerCameraBearingKey", "__Internal")]
NSString LayerCameraBearingKey { get; }
[Field ("kGMSLayerCameraZoomLevelKey", "__Internal")]
NSString LayerCameraZoomLevelKey { get; }
[Field ("kGMSLayerCameraViewingAngleKey", "__Internal")]
NSString LayerCameraViewingAngleKey { get; }
[Field ("kGMSMaxZoomLevel", "__Internal")]
float MaxZoomLevel { get; }
[Field ("kGMSMinZoomLevel", "__Internal")]
float MinZoomLevel { get; }
[Internal]
[Field ("kGMSGroundOverlayDefaultAnchor", "__Internal")]
IntPtr _GroundOverlayDefaultAnchor { get; }
[Internal]
[Field ("kGMSMarkerDefaultGroundAnchor", "__Internal")]
IntPtr _MarkerDefaultGroundAnchor { get; }
[Internal]
[Field ("kGMSMarkerDefaultInfoWindowAnchor", "__Internal")]
IntPtr _MarkerDefaultInfoWindowAnchor { get; }
[Internal]
[Field ("kGMSTileLayerNoTile", "__Internal")]
IntPtr _TileLayerNoTile { get; }
[Field ("kGMSLayerPanoramaFOVKey", "__Internal")]
NSString LayerPanoramaFOVKey { get; }
[Field ("kGMSLayerPanoramaHeadingKey", "__Internal")]
NSString LayerPanoramaHeadingKey { get; }
[Field ("kGMSLayerPanoramaPitchKey", "__Internal")]
NSString LayerPanoramaPitchKey { get; }
[Field ("kGMSLayerPanoramaZoomKey", "__Internal")]
NSString LayerPanoramaZoomKey { get; }
[Field ("kGMSMarkerLayerLatitude", "__Internal")]
NSString MarkerLayerLatitude { get; }
[Field ("kGMSMarkerLayerLongitude", "__Internal")]
NSString MarkerLayerLongitude { get; }
[Field ("kGMSMarkerLayerRotation", "__Internal")]
NSString MarkerLayerRotation { get; }
[Field ("kGMSAccessibilityCompass", "__Internal")]
NSString AccessibilityCompass { get; }
[Field ("kGMSAccessibilityMyLocation", "__Internal")]
NSString AccessibilityMyLocation { get; }
[Field ("kGMSAccessiblityOutOfQuota", "__Internal")]
NSString AccessiblityOutOfQuota { get; }
[Field ("kGMSEquatorProjectedMeter", "__Internal")]
double EquatorProjectedMeter { get; }
}
#endregion
[BaseType (typeof (NSObject), Name = "GMSAddress")]
interface Address : INSCopying
{
[Export ("coordinate")]
CLLocationCoordinate2D Coordinate { get; }
[NullAllowed]
[Export ("thoroughfare", ArgumentSemantic.Copy)]
string Thoroughfare { get; }
[NullAllowed]
[Export ("locality", ArgumentSemantic.Copy)]
string Locality { get; }
[NullAllowed]
[Export ("subLocality", ArgumentSemantic.Copy)]
string SubLocality { get; }
[NullAllowed]
[Export ("administrativeArea", ArgumentSemantic.Copy)]
string AdministrativeArea { get; }
[NullAllowed]
[Export ("postalCode", ArgumentSemantic.Copy)]
string PostalCode { get; }
[NullAllowed]
[Export ("country", ArgumentSemantic.Copy)]
string Country { get; }
[NullAllowed]
[Export ("lines", ArgumentSemantic.Copy)]
string [] Lines { get; }
[Obsolete ("This method is obsolete and will be removed in a future release. Use the Lines property instead.")]
[Export ("addressLine1")]
string AddressLine1 { get; }
[Obsolete ("This method is obsolete and will be removed in a future release. Use the Lines property instead.")]
[Export ("addressLine2")]
string AddressLine2 { get; }
}
[DisableDefaultCtor]
[BaseType (typeof (CALayer), Name = "GMSCALayer")]
interface Layer
{
}
[BaseType (typeof (NSObject), Name = "GMSCameraPosition")]
interface CameraPosition : INSCopying, INSMutableCopying
{
[Export ("target")]
CLLocationCoordinate2D Target { get; }
[Export ("zoom")]
float Zoom { get; }
[Export ("bearing")]
double Bearing { get; }
[Export ("viewingAngle")]
double ViewingAngle { get; }
[Export ("initWithTarget:zoom:bearing:viewingAngle:")]
NativeHandle Constructor (CLLocationCoordinate2D target, float zoom, double bearing, double viewingAngle);
// -(instancetype _Nonnull)initWithTarget:(CLLocationCoordinate2D)target zoom:(float)zoom;
[Export ("initWithTarget:zoom:")]
NativeHandle Constructor (CLLocationCoordinate2D target, float zoom);
// -(instancetype _Nonnull)initWithLatitude:(CLLocationDegrees)latitude longitude:(CLLocationDegrees)longitude zoom:(float)zoom;
[Export ("initWithLatitude:longitude:zoom:")]
NativeHandle Constructor (double latitude, double longitude, float zoom);
// -(instancetype _Nonnull)initWithLatitude:(CLLocationDegrees)latitude longitude:(CLLocationDegrees)longitude zoom:(float)zoom bearing:(CLLocationDirection)bearing viewingAngle:(double)viewingAngle;
[Export ("initWithLatitude:longitude:zoom:bearing:viewingAngle:")]
NativeHandle Constructor (double latitude, double longitude, float zoom, double bearing, double viewingAngle);
[Static, Export ("cameraWithTarget:zoom:")]
CameraPosition FromCamera (CLLocationCoordinate2D target, float zoom);
[Static, Export ("cameraWithLatitude:longitude:zoom:")]
CameraPosition FromCamera (double latitude, double longitude, float zoom);
[Static, Export ("cameraWithTarget:zoom:bearing:viewingAngle:")]
CameraPosition FromCamera (CLLocationCoordinate2D target, float zoom, double bearing, double viewingAngle);
[Static, Export ("cameraWithLatitude:longitude:zoom:bearing:viewingAngle:")]
CameraPosition FromCamera (double latitude, double longitude, float zoom, double bearing, double viewingAngle);
[Static, Export ("zoomAtCoordinate:forMeters:perPoints:")]
float ZoomAtCoordinate (CLLocationCoordinate2D coord, double meters, nfloat points);
}
[BaseType (typeof (CameraPosition), Name = "GMSMutableCameraPosition")]
interface MutableCameraPosition
{
[Export ("target", ArgumentSemantic.Assign)]
[New]
CLLocationCoordinate2D Target { get; set; }
[Export ("zoom", ArgumentSemantic.Assign)]
[New]
float Zoom { get; set; }
[Export ("bearing", ArgumentSemantic.Assign)]
[New]
double Bearing { get; set; }
[Export ("viewingAngle", ArgumentSemantic.Assign)]
[New]
double ViewingAngle { get; set; }
}
[DisableDefaultCtor]
[BaseType (typeof (NSObject), Name = "GMSCameraUpdate")]
interface CameraUpdate
{
[Static, Export ("zoomIn")]
CameraUpdate ZoomIn { get; }
[Static, Export ("zoomOut")]
CameraUpdate ZoomOut { get; }
[Static, Export ("zoomBy:")]
CameraUpdate ZoomByDelta (float delta);
[Static, Export ("zoomTo:")]
CameraUpdate ZoomToZoom (float zoom);
[Static, Export ("setTarget:")]
CameraUpdate SetTarget (CLLocationCoordinate2D target);
[Static, Export ("setTarget:zoom:")]
CameraUpdate SetTarget (CLLocationCoordinate2D target, float zoom);
[Static, Export ("setCamera:")]
CameraUpdate SetCamera (CameraPosition camera);
[Static, Export ("fitBounds:")]
CameraUpdate FitBounds (CoordinateBounds bounds);
[Static, Export ("fitBounds:withPadding:")]
CameraUpdate FitBounds (CoordinateBounds bounds, nfloat padding);
[Static, Export ("fitBounds:withEdgeInsets:")]
CameraUpdate FitBounds (CoordinateBounds bounds, UIEdgeInsets edgeInsets);
[Static, Export ("scrollByX:Y:")]
CameraUpdate Scroll (nfloat x, nfloat y);
[Static, Export ("zoomBy:atPoint:")]
CameraUpdate ZoomByZoom (float zoom, CGPoint point);
}
[BaseType (typeof (Overlay), Name = "GMSCircle")]
interface Circle
{
[Export ("position", ArgumentSemantic.Assign)]
CLLocationCoordinate2D Position { get; set; }
[Export ("radius", ArgumentSemantic.Assign)]
double Radius { get; set; }
[Export ("strokeWidth", ArgumentSemantic.Assign)]
nfloat StrokeWidth { get; set; }
[NullAllowed]
[Export ("strokeColor")]
UIColor StrokeColor { get; set; }
[NullAllowed]
[Export ("fillColor")]
UIColor FillColor { get; set; }
[Static, Export ("circleWithPosition:radius:")]
Circle FromPosition (CLLocationCoordinate2D position, double radius);
}
[BaseType (typeof (NSObject), Name = "GMSCoordinateBounds")]
interface CoordinateBounds
{
[Export ("northEast")]
CLLocationCoordinate2D NorthEast { get; }
[Export ("southWest")]
CLLocationCoordinate2D SouthWest { get; }
[Export ("valid")]
bool Valid { [Bind ("isValid")] get; }
[Export ("initWithCoordinate:coordinate:")]
NativeHandle Constructor (CLLocationCoordinate2D coord1, CLLocationCoordinate2D coord2);
[Export ("initWithRegion:")]
NativeHandle Constructor (VisibleRegion region);
[Export ("initWithPath:")]
NativeHandle Constructor (Google.Maps.Path path);
[Export ("includingCoordinate:")]
CoordinateBounds Including (CLLocationCoordinate2D coordinate);
[Export ("includingBounds:")]
CoordinateBounds Including (CoordinateBounds bounds);
[Export ("includingPath:")]
CoordinateBounds Including (Google.Maps.Path path);
[Export ("containsCoordinate:")]
bool ContainsCoordinate (CLLocationCoordinate2D coordinate);
[Export ("intersectsBounds:")]
bool IntersectsBounds (CoordinateBounds bounds);
}
delegate void ReverseGeocodeCallback ([NullAllowed] ReverseGeocodeResponse response, [NullAllowed] NSError error);
[BaseType (typeof (NSObject), Name = "GMSGeocoder")]
interface Geocoder
{
[Static, Export ("geocoder")]
Geocoder SharedGeocoder { get; }
[Async]
[Export ("reverseGeocodeCoordinate:completionHandler:")]
void ReverseGeocodeCord (CLLocationCoordinate2D coordinate, ReverseGeocodeCallback handler);
}
[BaseType (typeof (NSObject), Name = "GMSReverseGeocodeResponse")]
interface ReverseGeocodeResponse : INSCopying
{
[NullAllowed]
[Export ("firstResult")]
Address FirstResult { get; }
[NullAllowed]
[Export ("results")]
Address [] Results { get; }
}
[BaseType (typeof (Overlay), Name = "GMSGroundOverlay")]
interface GroundOverlay
{
[Export ("position")]
CLLocationCoordinate2D Position { get; set; }
[Export ("anchor")]
CGPoint Anchor { get; set; }
[NullAllowed]
[Export ("icon")]
UIImage Icon { get; set; }
// @property(nonatomic, assign) float opacity;
[Export ("opacity")]
float Opacity { get; set; }
[Export ("bearing")]
double Bearing { get; set; }
[NullAllowed]
[Export ("bounds")]
CoordinateBounds Bounds { get; set; }
[Static]
[Export ("groundOverlayWithBounds:icon:")]
GroundOverlay GetGroundOverlay ([NullAllowed] CoordinateBounds bounds, [NullAllowed] UIImage icon);
[Static]
[Export ("groundOverlayWithPosition:icon:zoomLevel:")]
GroundOverlay GetGroundOverlay (CLLocationCoordinate2D position, [NullAllowed] UIImage icon, nfloat zoomLevel);
}
[DisableDefaultCtor]
[BaseType (typeof (NSObject), Name = "GMSIndoorBuilding")]
interface IndoorBuilding
{
[Export ("levels", ArgumentSemantic.Retain)]
[PostGet ("Underground")]
IndoorLevel [] Levels { get; }
[Export ("defaultLevelIndex", ArgumentSemantic.Assign)]
nuint DefaultLevelIndex { get; }
[Export ("underground", ArgumentSemantic.Assign)]
bool Underground { [Bind ("isUnderground")] get; }
}
interface IIndoorDisplayDelegate
{
}
#if NET
[Model]
#else
[Model (AutoGeneratedName = true)]
#endif
[Protocol]
[BaseType (typeof (NSObject), Name = "GMSIndoorDisplayDelegate")]
interface IndoorDisplayDelegate
{
[Export ("didChangeActiveBuilding:")]
void DidChangeActiveBuilding ([NullAllowed] IndoorBuilding building);
[Export ("didChangeActiveLevel:")]
void DidChangeActiveLevel ([NullAllowed] IndoorLevel level);
}
[BaseType (typeof (NSObject), Name = "GMSIndoorDisplay")]
interface IndoorDisplay
{
[NullAllowed]
[Export ("delegate", ArgumentSemantic.Assign)]
IIndoorDisplayDelegate Delegate { get; set; }
[NullAllowed]
[Export ("activeBuilding")]
IndoorBuilding ActiveBuilding { get; }
[NullAllowed]
[Export ("activeLevel")]
IndoorLevel ActiveLevel { get; }
}
[DisableDefaultCtor]
[BaseType (typeof (NSObject), Name = "GMSIndoorLevel")]
interface IndoorLevel
{
[NullAllowed]
[Export ("name", ArgumentSemantic.Copy)]
string Name { get; }
[NullAllowed]
[Export ("shortName", ArgumentSemantic.Copy)]
string ShortName { get; }
}
[BaseType (typeof (Layer), Name = "GMSMapLayer")]
interface MapLayer
{
[Export ("cameraLatitude")]
double CameraLatitude { get; set; }
[Export ("cameraLongitude")]
double CameraLongitude { get; set; }
[Export ("cameraBearing")]
double CameraBearing { get; set; }
[Export ("cameraZoomLevel")]
float CameraZoomLevel { get; set; }
[Export ("cameraViewingAngle")]
double CameraViewingAngle { get; set; }
}
// @interface GMSMapStyle : NSObject
[DisableDefaultCtor]
[BaseType (typeof (NSObject), Name = "GMSMapStyle")]
interface MapStyle
{
// + (GMS_NULLABLE_INSTANCETYPE)styleWithJSONString:(NSString *)style error:(NSError* __autoreleasing GMS_NULLABLE_PTR*)error;
[Static]
[return: NullAllowed]
[Export ("styleWithJSONString:error:")]
MapStyle FromJson (string jsonStyle, [NullAllowed] NSError error);
// (GMS_NULLABLE_INSTANCETYPE) styleWithContentsOfFileURL:(NSURL*)fileURL error:(NSError* __autoreleasing GMS_NULLABLE_PTR*)error;
[Static]
[return: NullAllowed]
[Export ("styleWithContentsOfFileURL:error:")]
MapStyle FromUrl (NSUrl fileUrl, [NullAllowed] NSError error);
}
interface IMapViewDelegate
{
}
#if NET
[Model]
#else
[Model (AutoGeneratedName = true)]
#endif
[Protocol]
[BaseType (typeof (NSObject), Name = "GMSMapViewDelegate")]
interface MapViewDelegate
{
[Export ("mapView:willMove:"), EventArgs ("GMSWillMove"), EventName ("WillMove")]
void WillMove (MapView mapView, bool gesture);
[Export ("mapView:didChangeCameraPosition:"), EventArgs ("GMSCamera"), EventName ("CameraPositionChanged")]
void DidChangeCameraPosition (MapView mapView, CameraPosition position);
[Export ("mapView:idleAtCameraPosition:"), EventArgs ("GMSCamera"), EventName ("CameraPositionIdle")]
void IdleAtCameraPosition (MapView mapView, CameraPosition position);
[Export ("mapView:didTapAtCoordinate:"), EventArgs ("GMSCoord"), EventName ("CoordinateTapped")]
void DidTapAtCoordinate (MapView mapView, CLLocationCoordinate2D coordinate);
[Export ("mapView:didLongPressAtCoordinate:"), EventArgs ("GMSCoord"), EventName ("CoordinateLongPressed")]
void DidLongPressAtCoordinate (MapView mapView, CLLocationCoordinate2D coordinate);
[Export ("mapView:didTapMarker:"), DelegateName ("GMSTappedMarker"), DefaultValue (false)]
bool TappedMarker (MapView mapView, Marker marker);
[Export ("mapView:didTapInfoWindowOfMarker:"), EventArgs ("GMSMarkerEvent"), EventName ("InfoTapped")]
void DidTapInfoWindowOfMarker (MapView mapView, Marker marker);
// - (void)mapView:(GMSMapView *)mapView didLongPressInfoWindowOfMarker:(GMSMarker *)marker;
[Export ("mapView:didLongPressInfoWindowOfMarker:"), EventArgs ("GMSMarkerEvent"), EventName ("InfoLongPressed")]
void DidLongPressInfoWindowOfMarker (MapView mapView, Marker marker);
[Export ("mapView:didTapOverlay:"), EventArgs ("GMSOverlayEvent"), EventName ("OverlayTapped")]
void DidTapOverlay (MapView mapView, Overlay overlay);
// - (void)mapView:(GMSMapView *)mapView didTapPOIWithPlaceID:(NSString*)placeID name:(NSString*)name location:(CLLocationCoordinate2D)location;
[Export ("mapView:didTapPOIWithPlaceID:name:location:"), EventArgs ("GMSPoiWithPlaceIdEvent"), EventName ("PoiWithPlaceIdTapped")]
void DidTapPoiWithPlaceId (MapView mapView, string placeId, string name, CLLocationCoordinate2D location);
[Export ("mapView:markerInfoWindow:"), DelegateName ("GMSInfoFor"), DefaultValue (null)]
UIView MarkerInfoWindow (MapView mapView, Marker marker);
[Export ("mapView:markerInfoContents:"), DelegateName ("GMSInfoFor"), DefaultValue (null)]
UIView MarkerInfoContents (MapView mapView, Marker marker);
// - (void)mapView:(GMSMapView *)mapView didCloseInfoWindowOfMarker:(GMSMarker *)marker;
[Export ("mapView:didCloseInfoWindowOfMarker:"), EventArgs ("GMSMarkerEvent"), EventName ("InfoClosed")]
void DidCloseInfoWindowOfMarker (MapView mapView, Marker marker);
[Export ("mapView:didBeginDraggingMarker:"), EventArgs ("GMSMarkerEvent"), EventName ("DraggingMarkerStarted")]
void DidBeginDraggingMarker (MapView mapView, Marker marker);
[Export ("mapView:didEndDraggingMarker:"), EventArgs ("GMSMarkerEvent"), EventName ("DraggingMarkerEnded")]
void DidEndDraggingMarker (MapView mapView, Marker marker);
[Export ("mapView:didDragMarker:"), EventArgs ("GMSMarkerEvent"), EventName ("DraggingMarker")]
void DidDragMarker (MapView mapView, Marker marker);
[Export ("didTapMyLocationButtonForMapView:"), DelegateName ("GMSDidTapMyLocation"), DefaultValue (false)]
bool DidTapMyLocationButton (MapView mapView);
// - (void)mapView:(GMSMapView *)mapView didTapMyLocation:(CLLocationCoordinate2D)location;
[Export ("mapView:didTapMyLocation:"), EventArgs ("GMSMyLocationTapped"), EventName ("MyLocationTapped")]
void DidTapMyLocation (MapView mapView, CLLocationCoordinate2D location);
// - (void)mapViewDidStartTileRendering:(GMSMapView *)mapView;
[Export ("mapViewDidStartTileRendering:"), EventArgs ("GMSTileRendering"), EventName ("TileRenderingStarted")]
void DidStartTileRendering (MapView mapView);
// - (void)mapViewDidFinishTileRendering:(GMSMapView *)mapView;
[Export ("mapViewDidFinishTileRendering:"), EventArgs ("GMSTileRendering"), EventName ("TileRenderingEnded")]
void DidFinishTileRendering (MapView mapView);
// - (void)mapViewSnapshotReady:(GMSMapView *)mapView;
[Export ("mapViewSnapshotReady:"), EventArgs ("GMSSnapshotReady")]
void SnapshotReady (MapView mapView);
}
[BaseType (typeof (UIView), Name = "GMSMapView",
Delegates = new string [] { "Delegate" },
Events = new Type [] { typeof (MapViewDelegate) } )]
interface MapView
{
[Export ("initWithFrame:")]
NativeHandle Constructor (CGRect frame);
[NullAllowed]
[Export ("delegate", ArgumentSemantic.Assign)]
IMapViewDelegate Delegate { get; set; }
[Export ("camera", ArgumentSemantic.Copy)]
CameraPosition Camera { get; set; }
[Export ("projection")]
Projection Projection { get; }
[Export ("myLocationEnabled")]
bool MyLocationEnabled { [Bind ("isMyLocationEnabled")] get; set; }
[NullAllowed]
[Export ("myLocation")]
CLLocation MyLocation { get; }
[NullAllowed]
[Export ("selectedMarker")]
Marker SelectedMarker { get; set; }
[Export ("trafficEnabled")]
bool TrafficEnabled { [Bind ("isTrafficEnabled")] get; set; }
[Export ("mapType")]
MapViewType MapType { get; set; }
// @property(nonatomic, strong, nullable) GMSMapStyle *mapStyle;
[NullAllowed]
[Export ("mapStyle")]
MapStyle MapStyle { get; set; }
[Export ("minZoom")]
float MinZoom { get; }
[Export ("maxZoom")]
float MaxZoom { get; }
[Export ("buildingsEnabled")]
bool BuildingsEnabled { [Bind ("isBuildingsEnabled")] get; set; }
[Export ("indoorEnabled")]
bool IndoorEnabled { [Bind ("isIndoorEnabled")] get; set; }
[Export ("indoorDisplay")]
IndoorDisplay IndoorDisplay { get; }
[Export ("settings")]
UISettings Settings { get; }
[Export ("padding")]
UIEdgeInsets Padding { get; set; }
[Export ("paddingAdjustmentBehavior")]
MapViewPaddingAdjustmentBehavior PaddingAdjustmentBehavior { get; set; }
[Export ("accessibilityElementsHidden")]
[New]
bool AccessibilityElementsHidden { get; set; }
[Export ("layer", ArgumentSemantic.Retain)]
[New]
MapLayer Layer { get; }
// @property(nonatomic, assign) GMSFrameRate preferredFrameRate;
[Export ("preferredFrameRate")]
FrameRate PreferredFrameRate { get; set; }
// @property(nonatomic, nullable) GMSCoordinateBounds *cameraTargetBounds;
[NullAllowed]
[Export ("cameraTargetBounds")]
CoordinateBounds CameraTargetBounds { get; set; }
// -(instancetype _Nonnull)initWithFrame:(CGRect)frame camera:(GMSCameraPosition * _Nonnull)camera;
[Export ("initWithFrame:camera:")]
NativeHandle Constructor (CGRect frame, CameraPosition camera);
[Static]
[Export ("mapWithFrame:camera:")]
MapView FromCamera (CGRect frame, CameraPosition camera);
[Obsolete ("This method is obsolete and will be removed in a future release.")]
[Export ("startRendering")]
void StartRendering ();
[Obsolete ("This method is obsolete and will be removed in a future release.")]
[Export ("stopRendering")]
void StopRendering ();
[Export ("clear")]
void Clear ();
[Export ("setMinZoom:maxZoom:")]
void SetMinMaxZoom (float minZoom, float maxZoom);
[return: NullAllowed]
[Export ("cameraForBounds:insets:")]
CameraPosition CameraForBounds (CoordinateBounds bounds, UIEdgeInsets insets);
[Export ("moveCamera:")]
void MoveCamera (CameraUpdate update);
// - (BOOL)areEqualForRenderingPosition:(GMSCameraPosition *)position position:(GMSCameraPosition*)otherPosition;
[Export ("areEqualForRenderingPosition:position:")]
bool Equals (CameraPosition position, CameraPosition otherPosition);
///
/// From a category (GMSMapView+Premium.h)
///
// +(instancetype _Nonnull)mapWithFrame:(CGRect)frame mapID:(GMSMapID * _Nonnull)mapID camera:(GMSCameraPosition * _Nonnull)camera __attribute__((availability(swift, unavailable)));
[Static]
[Export ("mapWithFrame:mapID:camera:")]
MapView MapWithFrame (CGRect frame, MapId mapId, CameraPosition camera);
// -(instancetype _Nonnull)initWithFrame:(CGRect)frame mapID:(GMSMapID * _Nonnull)mapID camera:(GMSCameraPosition * _Nonnull)camera;
[Export ("initWithFrame:mapID:camera:")]
NativeHandle Constructor (CGRect frame, MapId mapId, CameraPosition camera);
}
[BaseType (typeof (MapView))]
[Category]
interface MapViewAnimation
{
[Export ("animateToCameraPosition:")]
void Animate (CameraPosition cameraPosition);
[Export ("animateToLocation:")]
void Animate (CLLocationCoordinate2D location);
[Export ("animateToZoom:")]
void Animate (float zoom);
[Export ("animateToBearing:")]
void AnimateToBearing (double bearing);
[Export ("animateToViewingAngle:")]
void Animate (double viewingAngle);
[Export ("animateWithCameraUpdate:")]
void Animate (CameraUpdate cameraUpdate);
}
[BaseType (typeof (Overlay), Name = "GMSMarker")]
interface Marker
{
[Export ("position")]
CLLocationCoordinate2D Position { get; set; }
[NullAllowed]
[Export ("snippet", ArgumentSemantic.Copy)]
string Snippet { get; set; }
[NullAllowed]
[Export ("icon")]
UIImage Icon { get; set; }
// @property(nonatomic, strong) UIView *iconView;
[NullAllowed]
[Export ("iconView")]
UIView IconView { get; set; }
// @property(nonatomic, assign) BOOL tracksViewChanges;
[Export ("tracksViewChanges")]
bool TracksViewChanges { get; set; }
// @property(nonatomic, assign) BOOL tracksInfoWindowChanges;
[Export ("tracksInfoWindowChanges")]
bool TracksInfoWindowChanges { get; set; }
[Export ("groundAnchor")]
CGPoint GroundAnchor { get; set; }
[Export ("infoWindowAnchor")]
CGPoint InfoWindowAnchor { get; set; }
[Export ("appearAnimation")]
MarkerAnimation AppearAnimation { get; set; }
[Export ("draggable")]
bool Draggable { [Bind ("isDraggable")] get; set; }
[Export ("flat")]
bool Flat { [Bind ("isFlat")] get; set; }
[Export ("rotation")]
double Rotation { get; set; }
[Export ("opacity")]
float Opacity { get; set; }
[Export ("layer")]
MarkerLayer Layer { get; }
[NullAllowed]
[Export ("panoramaView", ArgumentSemantic.Weak)]
PanoramaView PanoramaView { get; set; }
[Static]
[Export ("markerWithPosition:")]
Marker FromPosition (CLLocationCoordinate2D position);
[Static]
[Export ("markerImageWithColor:")]
UIImage MarkerImage ([NullAllowed] UIColor color);
///
/// From a category (GMSMarker+Premium.h)
///
// @property (nonatomic) GMSCollisionBehavior collisionBehavior;
[Export ("collisionBehavior", ArgumentSemantic.Assign)]
CollisionBehavior CollisionBehavior { get; set; }
}
[DisableDefaultCtor]
[BaseType (typeof (OverlayLayer), Name = "GMSMarkerLayer")]
interface MarkerLayer
{
[Export ("latitude")]
double Latitude { get; set; }
[Export ("longitude")]
double Longitude { get; set; }
[Export ("rotation")]
double Rotation { get; set; }
[New]
[Export ("opacity")]
float Opacity { get; set; }
}
[BaseType (typeof (Path), Name = "GMSMutablePath")]
interface MutablePath
{
[Export ("addCoordinate:")]
void AddCoordinate (CLLocationCoordinate2D coord);
[Export ("addLatitude:longitude:")]
void AddLatLon (double latitude, double longitude);
[Export ("insertCoordinate:atIndex:")]
void InsertCoordinate (CLLocationCoordinate2D coord, nuint index);
[Export ("replaceCoordinateAtIndex:withCoordinate:")]
void ReplaceCoordinate (nuint index, CLLocationCoordinate2D coord);
[Export ("removeCoordinateAtIndex:")]
void RemoveCoordinate (nuint index);
[Export ("removeLastCoordinate")]
void RemoveLastCoordinate ();
[Export ("removeAllCoordinates")]
void RemoveAllCoordinates ();
}
[DisableDefaultCtor]
[BaseType (typeof (NSObject), Name = "GMSOverlay")]
interface Overlay : INSCopying
{
[NullAllowed]
[Export ("title", ArgumentSemantic.Copy)]
string Title { get; set; }
[NullAllowed]
[Export ("map")]
MapView Map { get; set; }
[Export ("tappable")]
bool Tappable { [Bind ("isTappable")] get; set; }
[Export ("zIndex")]
int ZIndex { get; set; }
// @property(nonatomic, strong, nullable) id userData;
[NullAllowed]
[Export ("userData")]
NSObject UserData { get; set; }
}
// @interface GMSOverlayLayer : CALayer
[DisableDefaultCtor]
[BaseType (typeof (CALayer), Name = "GMSOverlayLayer")]
interface OverlayLayer { }
[DisableDefaultCtor]
[BaseType (typeof (NSObject), Name = "GMSPanorama")]
interface Panorama
{
[Export ("coordinate")]
CLLocationCoordinate2D Coordinate { get; }
[Export ("panoramaID")]
string PanoramaId { get; }
[Export ("links", ArgumentSemantic.Copy)]
PanoramaLink [] Links { get; }
}
[BaseType (typeof (NSObject), Name = "GMSPanoramaCamera")]
interface PanoramaCamera
{
[Export ("initWithOrientation:zoom:FOV:")]
NativeHandle Constructor (Orientation orientation, float zoom, double fov);
[Static]
[Export ("cameraWithOrientation:zoom:")]
PanoramaCamera FromOrientation (Orientation orientation, float zoom);
[Static]
[Export ("cameraWithHeading:pitch:zoom:")]
PanoramaCamera FromHeading (double heading, double pitch, float zoom);
[Static]
[Export ("cameraWithOrientation:zoom:FOV:")]
PanoramaCamera FromOrientation (Orientation orientation, float zoom, double fov);
[Static]
[Export ("cameraWithHeading:pitch:zoom:FOV:")]
PanoramaCamera FromHeading (double heading, double pitch, float zoom, double fov);
[Export ("FOV")]
double Fov { get; }
[Export ("zoom")]
float Zoom { get; }
[Export ("orientation")]
Orientation Orientation { get; }
}
[DisableDefaultCtor]
[BaseType (typeof (NSObject), Name = "GMSPanoramaCameraUpdate")]
interface PanoramaCameraUpdate
{
[Static]
[Export ("rotateBy:")]
PanoramaCameraUpdate Rotate (nfloat deltaHeading);
[Static]
[Export ("setHeading:")]
PanoramaCameraUpdate SetHeading (nfloat heading);
[Static]
[Export ("setPitch:")]
PanoramaCameraUpdate SetPitch (nfloat pitch);
[Static]
[Export ("setZoom:")]
PanoramaCameraUpdate SetZoom (nfloat zoom);
}
[DisableDefaultCtor]
[BaseType (typeof (CALayer), Name = "GMSPanoramaLayer")]
interface PanoramaLayer
{
[Export ("cameraHeading")]
double CameraHeading { get; set; }
[Export ("cameraPitch")]
double CameraPitch { get; set; }
[Export ("cameraZoom")]
float CameraZoom { get; set; }
[Export ("cameraFOV")]
double CameraFOV { get; set; }
}
[BaseType (typeof (NSObject), Name = "GMSPanoramaLink")]
interface PanoramaLink
{
[Export ("heading")]
nfloat Heading { get; set; }
[Export ("panoramaID", ArgumentSemantic.Copy)]
string PanoramaId { get; set; }
}
delegate void PanoramaCallback ([NullAllowed] Panorama panorama, [NullAllowed] NSError error);
[BaseType (typeof (NSObject), Name = "GMSPanoramaService")]
interface PanoramaService
{
[Async]
[Export ("requestPanoramaNearCoordinate:callback:")]
void RequestPanorama (CLLocationCoordinate2D coordinate, PanoramaCallback callback);
[Async]
[Export ("requestPanoramaNearCoordinate:radius:callback:")]
void RequestPanorama (CLLocationCoordinate2D coordinate, nuint radius, PanoramaCallback callback);
// - (void)requestPanoramaNearCoordinate:(CLLocationCoordinate2D)coordinate source:(GMSPanoramaSource)source callback:(GMSPanoramaCallback)callback;
[Async]
[Export ("requestPanoramaNearCoordinate:source:callback:")]
void RequestPanorama (CLLocationCoordinate2D coordinate, PanoramaSource source, PanoramaCallback callback);
// - (void) requestPanoramaNearCoordinate:(CLLocationCoordinate2D)coordinate radius:(NSUInteger)radius source:(GMSPanoramaSource)source callback:(GMSPanoramaCallback)callback;
[Async]
[Export ("requestPanoramaNearCoordinate:radius:source:callback:")]
void RequestPanorama (CLLocationCoordinate2D coordinate, nuint radius, PanoramaSource source, PanoramaCallback callback);
[Async]
[Export ("requestPanoramaWithID:callback:")]
void RequestPanorama (string panoramaId, PanoramaCallback callback);
}
interface IPanoramaViewDelegate
{
}
#if NET
[Model]