-
-
Notifications
You must be signed in to change notification settings - Fork 937
Expand file tree
/
Copy pathNativeMapViewModule.ts
More file actions
75 lines (73 loc) · 2.41 KB
/
NativeMapViewModule.ts
File metadata and controls
75 lines (73 loc) · 2.41 KB
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
import type { TurboModule, CodegenTypes } from 'react-native';
import { TurboModuleRegistry } from 'react-native';
export interface Spec extends TurboModule {
takeSnap: (
viewRef: CodegenTypes.Int32 | null,
writeToDisk: boolean,
) => Promise<Object>;
queryTerrainElevation: (
viewRef: CodegenTypes.Int32 | null,
coordinates: ReadonlyArray<number>,
) => Promise<Object>;
setSourceVisibility: (
viewRef: CodegenTypes.Int32 | null,
visible: boolean,
sourceId: string,
sourceLayerId: string,
) => Promise<Object>;
getCenter: (viewRef: CodegenTypes.Int32 | null) => Promise<Object>;
getCoordinateFromView: (
viewRef: CodegenTypes.Int32 | null,
atPoint: ReadonlyArray<number>,
) => Promise<Object>;
getPointInView: (
viewRef: CodegenTypes.Int32 | null,
atCoordinate: ReadonlyArray<number>,
) => Promise<Object>;
getZoom: (viewRef: CodegenTypes.Int32 | null) => Promise<Object>;
getVisibleBounds: (viewRef: CodegenTypes.Int32 | null) => Promise<Object>;
queryRenderedFeaturesAtPoint: (
viewRef: CodegenTypes.Int32 | null,
atPoint: ReadonlyArray<number>,
withFilter: ReadonlyArray<Object>,
withLayerIDs: ReadonlyArray<string>,
) => Promise<Object>;
queryRenderedFeaturesInRect: (
viewRef: CodegenTypes.Int32 | null,
withBBox: ReadonlyArray<number>,
withFilter: ReadonlyArray<Object>,
withLayerIDs: ReadonlyArray<string>,
) => Promise<Object>;
setHandledMapChangedEvents: (
viewRef: CodegenTypes.Int32 | null,
events: ReadonlyArray<string>,
) => Promise<Object>;
clearData: (viewRef: CodegenTypes.Int32 | null) => Promise<Object>;
querySourceFeatures: (
viewRef: CodegenTypes.Int32 | null,
sourceId: string,
withFilter: ReadonlyArray<Object>,
withSourceLayerIDs: ReadonlyArray<string>,
) => Promise<Object>;
setFeatureState: (
viewRef: CodegenTypes.Int32 | null,
featureId: string,
state: Object,
sourceId: string,
sourceLayerId: string | null,
) => Promise<Object>;
getFeatureState: (
viewRef: CodegenTypes.Int32 | null,
featureId: string,
sourceId: string,
sourceLayerId: string | null,
) => Promise<Object>;
removeFeatureState: (
viewRef: CodegenTypes.Int32 | null,
featureId: string,
stateKey: string | null,
sourceId: string,
sourceLayerId: string | null,
) => Promise<Object>;
}
export default TurboModuleRegistry.getEnforcing<Spec>('RNMBXMapViewModule');