1
- /**
2
- * iOS and Android apis should match.
3
- * It doesn't matter if you export `.ios` or `.android`, either one but only one.
4
- */
5
- export * from './mapbox.ios' ;
1
+ import { ImageSource } from '@nativescript/core' ;
2
+ import { AddExtrusionOptions , AddGeoJsonClusteredOptions , AddPolygonOptions , AddPolylineOptions , AddSourceOptions , AnimateCameraOptions , DeleteOfflineRegionOptions , DownloadOfflineRegionOptions , Feature , LatLng , LayerCommon , ListOfflineRegionsOptions , MapboxApi , MapboxCommon , MapboxMarker , MapboxViewBase , MapStyle , OfflineRegion , QueryRenderedFeaturesOptions , QuerySourceFeaturesOptions , SetCenterOptions , SetTiltOptions , SetViewportOptions , SetZoomLevelOptions , ShowOptions , TrackUserOptions , UpdateSourceOptions , UserLocation , UserLocationCameraMode , Viewport } from './common' ;
6
3
7
4
// Export any shared classes, constants, etc.
8
- export * from './mapbox.common' ;
5
+ export * from './common' ;
6
+
7
+ export declare function setLogLevel ( level : 'none' | 'info' | 'debug' | 'error' | 'fault' | 'verbose' ) : void ;
8
+ export declare class MapboxView extends MapboxViewBase {
9
+ private nativeMapView ;
10
+ private delegate ;
11
+ private settings ;
12
+ private initialized ;
13
+ private initCountHack ;
14
+ setConfig ( settings : any ) : void ;
15
+ getNativeMapView ( ) : any ;
16
+ createNativeView ( ) : Object ;
17
+ onLoaded ( ) : void ;
18
+ initNativeView ( ) : void ;
19
+ disposeNativeView ( ) : Promise < void > ;
20
+ getMapboxApi ( ) : any ;
21
+ initMap ( ) : void ;
22
+ onLayout ( left : number , top : number , right : number , bottom : number ) : void ;
23
+ }
24
+ export declare class Mapbox extends MapboxCommon implements MapboxApi {
25
+ private _mapboxViewInstance ;
26
+ private eventCallbacks ;
27
+ private userLocationRenderMode ;
28
+ setMapboxViewInstance ( mapboxViewInstance : any ) : void ;
29
+ initEventHandlerShim ( settings : any , mapboxNativeViewInstance : any ) : void ;
30
+ onMapEvent ( eventName : any , id : any , callback : any , nativeMapView ?: any ) : void ;
31
+ offMapEvent ( eventName : any , id : any , nativeMapView ?: any ) : void ;
32
+ private checkForClickEvent ;
33
+ private _addMarkers ;
34
+ show ( options : ShowOptions ) : Promise < any > ;
35
+ hide ( ) : Promise < void > ;
36
+ unhide ( ) : Promise < void > ;
37
+ destroy ( nativeMap ?: any ) : Promise < void > ;
38
+ onStart ( nativeMap ?: any ) : Promise < void > ;
39
+ onResume ( nativeMap ?: any ) : Promise < void > ;
40
+ onPause ( nativeMap ?: any ) : Promise < void > ;
41
+ onStop ( nativeMap ?: any ) : Promise < void > ;
42
+ onLowMemory ( nativeMap ?: any ) : Promise < void > ;
43
+ onDestroy ( nativeMap ?: any ) : Promise < void > ;
44
+ setMapStyle ( style : string | MapStyle , nativeMap ?: any ) : Promise < void > ;
45
+ getImage ( imageId : string , nativeMap ?: any ) : Promise < ImageSource > ;
46
+ addImage ( imageId : string , image : string , nativeMap ?: any ) : Promise < void > ;
47
+ removeImage ( imageId : string , nativeMap ?: any ) : Promise < void > ;
48
+ addMarkers ( markers : MapboxMarker [ ] , nativeMap ?: any ) : Promise < void > ;
49
+ removeMarkers ( ids ?: any , nativeMap ?: any ) : Promise < void > ;
50
+ setCenter ( options : SetCenterOptions , nativeMap ?: any ) : Promise < void > ;
51
+ getCenter ( nativeMap ?: any ) : Promise < LatLng > ;
52
+ setZoomLevel ( options : SetZoomLevelOptions , nativeMap ?: any ) : Promise < void > ;
53
+ getZoomLevel ( nativeMap ?: any ) : Promise < number > ;
54
+ setTilt ( options : SetTiltOptions , nativeMap ?: any ) : Promise < void > ;
55
+ getTilt ( nativeMap ?: any ) : Promise < number > ;
56
+ getUserLocation ( nativeMap ?: any ) : Promise < UserLocation > ;
57
+ _stringToCameraMode ( mode : UserLocationCameraMode ) : any ;
58
+ _stringToRenderMode ( mode : any ) : any ;
59
+ showUserLocationMarker ( options : any , nativeMap ?: any ) : Promise < void > ;
60
+ hideUserLocationMarker ( nativeMap ?: any ) : Promise < void > ;
61
+ changeUserLocationMarkerMode ( renderModeString : any , cameraModeString : UserLocationCameraMode , nativeMap ?: any ) : Promise < void > ;
62
+ forceUserLocationUpdate ( location : any , nativeMap ?: any ) : void ;
63
+ queryRenderedFeatures ( options : QueryRenderedFeaturesOptions , nativeMap ?: any ) : Promise < Feature [ ] > ;
64
+ querySourceFeatures ( sourceId : string , options ?: QuerySourceFeaturesOptions , nativeMap ?: any ) : Promise < Feature [ ] > ;
65
+ addPolygon ( options : AddPolygonOptions , nativeMap ?: any ) : Promise < void > ;
66
+ addPolyline ( options : AddPolylineOptions , nativeMap ?: any ) : Promise < void > ;
67
+ private removePolyById ;
68
+ private removePolys ;
69
+ removePolygons ( ids ?: any [ ] , nativeMap ?: any ) : Promise < void > ;
70
+ removePolylines ( ids ?: any [ ] , nativeMap ?: any ) : Promise < void > ;
71
+ animateCamera ( options : AnimateCameraOptions , nativeMap ?: any ) : Promise < void > ;
72
+ setOnMapClickListener ( listener : ( data : LatLng ) => void , nativeMap ?: any ) : Promise < void > ;
73
+ setOnMapLongClickListener ( listener : ( data : LatLng ) => void , nativeMap ?: any ) : Promise < void > ;
74
+ setOnScrollListener ( listener : ( data ?: LatLng ) => void , nativeMap ?: any ) : Promise < void > ;
75
+ setOnMoveBeginListener ( listener : ( data ?: LatLng ) => void , nativeMap ?: any ) : Promise < void > ;
76
+ setOnFlingListener ( listener : ( ) => void , nativeMap ?: any ) : Promise < void > ;
77
+ setOnCameraMoveListener ( listener : ( reason : any , animated ?: any ) => void , nativeMap ?: any ) : Promise < void > ;
78
+ setOnCameraMoveCancelListener ( listener : ( ) => void , nativeMap ?: any ) : Promise < void > ;
79
+ setOnCameraIdleListener ( listener : ( ) => void , nativeMap ?: any ) : Promise < void > ;
80
+ getViewport ( nativeMap ?: any ) : Promise < Viewport > ;
81
+ setViewport ( options : SetViewportOptions , nativeMap ?: any ) : Promise < void > ;
82
+ downloadOfflineRegion ( options : DownloadOfflineRegionOptions ) : Promise < void > ;
83
+ listOfflineRegions ( options ?: ListOfflineRegionsOptions ) : Promise < OfflineRegion [ ] > ;
84
+ deleteOfflineRegion ( options : DeleteOfflineRegionOptions ) : Promise < void > ;
85
+ addExtrusion ( options : AddExtrusionOptions , nativeMap ?: any ) : Promise < void > ;
86
+ updateSource ( id : string , options : UpdateSourceOptions , nativeMap ?: any ) : Promise < unknown > ;
87
+ addSource ( id : string , options : AddSourceOptions , nativeMap ?: any ) : Promise < void > ;
88
+ removeSource ( id : string , nativeMap ?: any ) : Promise < void > ;
89
+ addLayer ( style : any , belowLayerId ?: string , nativeMapView ?: any ) : Promise < void > ;
90
+ removeLayer ( id : string , nativeMapViewInstance ?: any ) : Promise < void > ;
91
+ addLinePoint ( id : string , lnglat : any , sourceId ?: string , nativeMapView ?: any ) : Promise < void > ;
92
+ addGeoJsonClustered ( options : AddGeoJsonClusteredOptions , nativeMapViewInstance ?: any ) : Promise < void > ;
93
+ trackUser ( options : TrackUserOptions , nativeMap ?: any ) : Promise < void > ;
94
+ getLayer ( name : string , nativeMap ?: any ) : Promise < LayerCommon > ;
95
+ getLayers ( nativeMap ?: any ) : Promise < LayerCommon [ ] > ;
96
+ project ( data : LatLng ) : {
97
+ x : number ;
98
+ y : number ;
99
+ } ;
100
+ }
0 commit comments