@maydon_tech/react-native-nitro-maps 0.1.3 → 0.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +1 -1
- package/NitroMap.podspec +1 -1
- package/README.md +82 -9
- package/android/CMakeLists.txt +4 -1
- package/android/gradle.properties +4 -4
- package/android/src/main/cpp/ClusterEngineJNI.cpp +198 -0
- package/android/src/main/kotlin/com/margelo/nitro/nitromap/NitroMap.kt +397 -0
- package/android/src/main/kotlin/com/margelo/nitro/nitromap/NitroMapConfig.kt +53 -0
- package/android/src/main/{java → kotlin}/com/margelo/nitro/nitromap/NitroMapPackage.kt +4 -4
- package/android/src/main/kotlin/com/margelo/nitro/nitromap/NitroMapView.kt +73 -0
- package/android/src/main/kotlin/com/margelo/nitro/nitromap/UserLocationManager.kt +295 -0
- package/android/src/main/kotlin/com/margelo/nitro/nitromap/clustering/ClusterIconRenderer.kt +111 -0
- package/android/src/main/kotlin/com/margelo/nitro/nitromap/clustering/ClusteringManager.kt +104 -0
- package/android/src/main/kotlin/com/margelo/nitro/nitromap/clustering/NitroClusterEngine.kt +166 -0
- package/android/src/main/kotlin/com/margelo/nitro/nitromap/markers/MarkerIconFactory.kt +303 -0
- package/android/src/main/kotlin/com/margelo/nitro/nitromap/markers/MarkerSelectionHandler.kt +72 -0
- package/android/src/main/kotlin/com/margelo/nitro/nitromap/markers/PriceMarkerRenderer.kt +159 -0
- package/android/src/main/kotlin/com/margelo/nitro/nitromap/providers/MapProviderFactory.kt +24 -0
- package/android/src/main/kotlin/com/margelo/nitro/nitromap/providers/MapProviderInterface.kt +128 -0
- package/android/src/main/kotlin/com/margelo/nitro/nitromap/providers/google/GoogleMapDelegate.kt +317 -0
- package/android/src/main/kotlin/com/margelo/nitro/nitromap/providers/google/GoogleMapProvider+Clustering.kt +524 -0
- package/android/src/main/kotlin/com/margelo/nitro/nitromap/providers/google/GoogleMapProvider+Markers.kt +358 -0
- package/android/src/main/kotlin/com/margelo/nitro/nitromap/providers/google/GoogleMapProvider+Overlays.kt +272 -0
- package/android/src/main/kotlin/com/margelo/nitro/nitromap/providers/google/GoogleMapProvider+UserLocation.kt +296 -0
- package/android/src/main/kotlin/com/margelo/nitro/nitromap/providers/google/GoogleMapProvider.kt +815 -0
- package/android/src/main/kotlin/com/margelo/nitro/nitromap/providers/google/MarkerTagData.kt +19 -0
- package/ios/Clustering/ClusterIconRenderer.swift +3 -3
- package/ios/Location/NitroLocationManager.swift +116 -0
- package/ios/MarkerRenderer/MarkerIconFactory.swift +1 -3
- package/ios/MarkerRenderer/PriceMarkerRenderer.swift +10 -6
- package/ios/NitroMap.swift +279 -13
- package/ios/NitroMapConfig/NitroMapConfig.swift +45 -0
- package/ios/Providers/{GoogleMapDelegate.swift → Google/GoogleMapDelegate.swift} +48 -23
- package/ios/Providers/Google/GoogleMapProvider+Camera.swift +180 -0
- package/ios/Providers/Google/GoogleMapProvider+Clustering.swift +541 -0
- package/ios/Providers/Google/GoogleMapProvider+Markers.swift +270 -0
- package/ios/Providers/Google/GoogleMapProvider+Overlays.swift +245 -0
- package/ios/Providers/Google/GoogleMapProvider+UserLocation.swift +180 -0
- package/ios/Providers/Google/GoogleMapProvider.swift +342 -0
- package/ios/Providers/MapProviderFactory.swift +17 -0
- package/ios/Providers/MapProviderProtocol.swift +48 -1
- package/ios/Shared/ClusterConfig+Factory.swift +2 -2
- package/ios/Shared/MapStyleProvider.swift +6 -4
- package/ios/Shared/MarkerSelectionHandler.swift +4 -1
- package/ios/Utils/ColorValueExtension.swift +46 -67
- package/lib/module/components/ImageMarker.js +39 -29
- package/lib/module/components/ImageMarker.js.map +1 -1
- package/lib/module/components/Marker.js +118 -0
- package/lib/module/components/Marker.js.map +1 -0
- package/lib/module/components/NitroCircle.js +92 -0
- package/lib/module/components/NitroCircle.js.map +1 -0
- package/lib/module/components/NitroMap.js +216 -76
- package/lib/module/components/NitroMap.js.map +1 -1
- package/lib/module/components/NitroPolygon.js +135 -0
- package/lib/module/components/NitroPolygon.js.map +1 -0
- package/lib/module/components/NitroPolyline.js +115 -0
- package/lib/module/components/NitroPolyline.js.map +1 -0
- package/lib/module/components/PriceMarker.js +16 -29
- package/lib/module/components/PriceMarker.js.map +1 -1
- package/lib/module/context/NitroMapContext.js.map +1 -1
- package/lib/module/hooks/useNitroCircle.js +18 -0
- package/lib/module/hooks/useNitroCircle.js.map +1 -0
- package/lib/module/hooks/useNitroMarker.js +26 -9
- package/lib/module/hooks/useNitroMarker.js.map +1 -1
- package/lib/module/hooks/useNitroOverlay.js +59 -0
- package/lib/module/hooks/useNitroOverlay.js.map +1 -0
- package/lib/module/hooks/useNitroPolygon.js +18 -0
- package/lib/module/hooks/useNitroPolygon.js.map +1 -0
- package/lib/module/hooks/useNitroPolyline.js +18 -0
- package/lib/module/hooks/useNitroPolyline.js.map +1 -0
- package/lib/module/index.js +5 -0
- package/lib/module/index.js.map +1 -1
- package/lib/module/types/overlay.js +4 -0
- package/lib/module/types/overlay.js.map +1 -0
- package/lib/module/types/theme.js +4 -0
- package/lib/module/types/theme.js.map +1 -0
- package/lib/module/utils/colors.js +41 -13
- package/lib/module/utils/colors.js.map +1 -1
- package/lib/module/utils/validation.js +45 -0
- package/lib/module/utils/validation.js.map +1 -0
- package/lib/typescript/src/components/ImageMarker.d.ts.map +1 -1
- package/lib/typescript/src/components/Marker.d.ts +34 -0
- package/lib/typescript/src/components/Marker.d.ts.map +1 -0
- package/lib/typescript/src/components/NitroCircle.d.ts +70 -0
- package/lib/typescript/src/components/NitroCircle.d.ts.map +1 -0
- package/lib/typescript/src/components/NitroMap.d.ts +60 -3
- package/lib/typescript/src/components/NitroMap.d.ts.map +1 -1
- package/lib/typescript/src/components/NitroPolygon.d.ts +86 -0
- package/lib/typescript/src/components/NitroPolygon.d.ts.map +1 -0
- package/lib/typescript/src/components/NitroPolyline.d.ts +84 -0
- package/lib/typescript/src/components/NitroPolyline.d.ts.map +1 -0
- package/lib/typescript/src/components/PriceMarker.d.ts +0 -5
- package/lib/typescript/src/components/PriceMarker.d.ts.map +1 -1
- package/lib/typescript/src/context/NitroMapContext.d.ts +2 -0
- package/lib/typescript/src/context/NitroMapContext.d.ts.map +1 -1
- package/lib/typescript/src/hooks/useNitroCircle.d.ts +7 -0
- package/lib/typescript/src/hooks/useNitroCircle.d.ts.map +1 -0
- package/lib/typescript/src/hooks/useNitroMarker.d.ts +20 -0
- package/lib/typescript/src/hooks/useNitroMarker.d.ts.map +1 -1
- package/lib/typescript/src/hooks/useNitroOverlay.d.ts +26 -0
- package/lib/typescript/src/hooks/useNitroOverlay.d.ts.map +1 -0
- package/lib/typescript/src/hooks/useNitroPolygon.d.ts +7 -0
- package/lib/typescript/src/hooks/useNitroPolygon.d.ts.map +1 -0
- package/lib/typescript/src/hooks/useNitroPolyline.d.ts +7 -0
- package/lib/typescript/src/hooks/useNitroPolyline.d.ts.map +1 -0
- package/lib/typescript/src/index.d.ts +15 -2
- package/lib/typescript/src/index.d.ts.map +1 -1
- package/lib/typescript/src/specs/NitroMap.nitro.d.ts +248 -6
- package/lib/typescript/src/specs/NitroMap.nitro.d.ts.map +1 -1
- package/lib/typescript/src/types/map.d.ts +34 -4
- package/lib/typescript/src/types/map.d.ts.map +1 -1
- package/lib/typescript/src/types/marker.d.ts +24 -36
- package/lib/typescript/src/types/marker.d.ts.map +1 -1
- package/lib/typescript/src/types/overlay.d.ts +75 -0
- package/lib/typescript/src/types/overlay.d.ts.map +1 -0
- package/lib/typescript/src/types/theme.d.ts +93 -0
- package/lib/typescript/src/types/theme.d.ts.map +1 -0
- package/lib/typescript/src/utils/colors.d.ts +6 -8
- package/lib/typescript/src/utils/colors.d.ts.map +1 -1
- package/lib/typescript/src/utils/validation.d.ts +12 -0
- package/lib/typescript/src/utils/validation.d.ts.map +1 -0
- package/nitrogen/generated/android/c++/JCircleData.hpp +94 -0
- package/nitrogen/generated/android/c++/JClusterConfig.hpp +5 -7
- package/nitrogen/generated/android/c++/JFunc_void_UserLocationChangeEvent.hpp +79 -0
- package/nitrogen/generated/android/c++/JFunc_void_UserTrackingMode.hpp +77 -0
- package/nitrogen/generated/android/c++/JFunc_void_std__string.hpp +76 -0
- package/nitrogen/generated/android/c++/JHybridNitroMapSpec.cpp +328 -21
- package/nitrogen/generated/android/c++/JHybridNitroMapSpec.hpp +53 -2
- package/nitrogen/generated/android/c++/JMarkerAnimation.hpp +3 -6
- package/nitrogen/generated/android/c++/JMarkerData.hpp +15 -3
- package/nitrogen/generated/android/c++/JPolygonData.hpp +149 -0
- package/nitrogen/generated/android/c++/JPolylineData.hpp +113 -0
- package/nitrogen/generated/android/c++/JUserLocationChangeEvent.hpp +70 -0
- package/nitrogen/generated/android/c++/JUserTrackingMode.hpp +62 -0
- package/nitrogen/generated/android/c++/views/JHybridNitroMapStateUpdater.cpp +72 -4
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/nitromap/CircleData.kt +62 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/nitromap/ClusterConfig.kt +4 -4
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/nitromap/Func_void_UserLocationChangeEvent.kt +80 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/nitromap/Func_void_UserTrackingMode.kt +80 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/nitromap/Func_void_std__string.kt +80 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/nitromap/HybridNitroMapSpec.kt +228 -2
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/nitromap/MarkerAnimation.kt +1 -2
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/nitromap/MarkerData.kt +12 -3
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/nitromap/PolygonData.kt +62 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/nitromap/PolylineData.kt +62 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/nitromap/UserLocationChangeEvent.kt +47 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/nitromap/{ClusterAnimationStyle.kt → UserTrackingMode.kt} +6 -8
- package/nitrogen/generated/android/nitromapOnLoad.cpp +6 -0
- package/nitrogen/generated/ios/NitroMap-Swift-Cxx-Bridge.cpp +24 -0
- package/nitrogen/generated/ios/NitroMap-Swift-Cxx-Bridge.hpp +175 -17
- package/nitrogen/generated/ios/NitroMap-Swift-Cxx-Umbrella.hpp +15 -3
- package/nitrogen/generated/ios/c++/HybridNitroMapSpecSwift.hpp +249 -16
- package/nitrogen/generated/ios/c++/views/HybridNitroMapComponent.mm +90 -5
- package/nitrogen/generated/ios/swift/CircleData.swift +143 -0
- package/nitrogen/generated/ios/swift/ClusterConfig.swift +22 -15
- package/nitrogen/generated/ios/swift/Func_void_UserLocationChangeEvent.swift +47 -0
- package/nitrogen/generated/ios/swift/Func_void_UserTrackingMode.swift +47 -0
- package/nitrogen/generated/ios/swift/Func_void_std__string.swift +47 -0
- package/nitrogen/generated/ios/swift/HybridNitroMapSpec.swift +35 -1
- package/nitrogen/generated/ios/swift/HybridNitroMapSpec_cxx.swift +582 -8
- package/nitrogen/generated/ios/swift/MarkerAnimation.swift +4 -8
- package/nitrogen/generated/ios/swift/MarkerData.swift +54 -2
- package/nitrogen/generated/ios/swift/PolygonData.swift +179 -0
- package/nitrogen/generated/ios/swift/PolylineData.swift +155 -0
- package/nitrogen/generated/ios/swift/UserLocationChangeEvent.swift +69 -0
- package/nitrogen/generated/ios/swift/UserTrackingMode.swift +44 -0
- package/nitrogen/generated/shared/c++/CircleData.hpp +113 -0
- package/nitrogen/generated/shared/c++/ClusterConfig.hpp +5 -8
- package/nitrogen/generated/shared/c++/HybridNitroMapSpec.cpp +53 -2
- package/nitrogen/generated/shared/c++/HybridNitroMapSpec.hpp +75 -6
- package/nitrogen/generated/shared/c++/MarkerAnimation.hpp +4 -8
- package/nitrogen/generated/shared/c++/MarkerData.hpp +14 -2
- package/nitrogen/generated/shared/c++/PolygonData.hpp +114 -0
- package/nitrogen/generated/shared/c++/PolylineData.hpp +114 -0
- package/nitrogen/generated/shared/c++/UserLocationChangeEvent.hpp +88 -0
- package/nitrogen/generated/shared/c++/UserTrackingMode.hpp +80 -0
- package/nitrogen/generated/shared/c++/views/HybridNitroMapComponent.cpp +216 -12
- package/nitrogen/generated/shared/c++/views/HybridNitroMapComponent.hpp +23 -1
- package/nitrogen/generated/shared/json/NitroMapConfig.json +18 -1
- package/package.json +36 -5
- package/src/components/ImageMarker.tsx +58 -42
- package/src/components/Marker.tsx +161 -0
- package/src/components/NitroCircle.tsx +183 -0
- package/src/components/NitroMap.tsx +328 -78
- package/src/components/NitroPolygon.tsx +229 -0
- package/src/components/NitroPolyline.tsx +208 -0
- package/src/components/PriceMarker.tsx +23 -48
- package/src/context/NitroMapContext.tsx +4 -0
- package/src/hooks/useNitroCircle.ts +25 -0
- package/src/hooks/useNitroMarker.ts +49 -10
- package/src/hooks/useNitroOverlay.ts +68 -0
- package/src/hooks/useNitroPolygon.ts +25 -0
- package/src/hooks/useNitroPolyline.ts +25 -0
- package/src/index.tsx +23 -2
- package/src/specs/NitroMap.nitro.ts +294 -5
- package/src/types/map.ts +36 -4
- package/src/types/marker.ts +24 -44
- package/src/types/overlay.ts +77 -0
- package/src/types/theme.ts +101 -0
- package/src/utils/colors.ts +48 -16
- package/src/utils/validation.ts +69 -0
- package/android/src/main/java/com/margelo/nitro/nitromap/ClusterIconGenerator.kt +0 -108
- package/android/src/main/java/com/margelo/nitro/nitromap/ColorUtils.kt +0 -63
- package/android/src/main/java/com/margelo/nitro/nitromap/HybridNitroMap.kt +0 -408
- package/android/src/main/java/com/margelo/nitro/nitromap/HybridNitroMapConfig.kt +0 -68
- package/android/src/main/java/com/margelo/nitro/nitromap/MarkerIconCache.kt +0 -176
- package/android/src/main/java/com/margelo/nitro/nitromap/MarkerIconFactory.kt +0 -252
- package/android/src/main/java/com/margelo/nitro/nitromap/clustering/NitroClusterEngine.kt +0 -252
- package/android/src/main/java/com/margelo/nitro/nitromap/clustering/QuadTree.kt +0 -195
- package/android/src/main/java/com/margelo/nitro/nitromap/providers/GoogleMapProvider.kt +0 -912
- package/android/src/main/java/com/margelo/nitro/nitromap/providers/MapProviderInterface.kt +0 -70
- package/cpp/QuadTree.hpp +0 -246
- package/ios/NitroMapConfig/HybridNitroMapConfig.swift +0 -33
- package/ios/Providers/GoogleMapProvider+Camera.swift +0 -164
- package/ios/Providers/GoogleMapProvider.swift +0 -924
- package/nitrogen/generated/android/c++/JClusterAnimationStyle.hpp +0 -68
- package/nitrogen/generated/ios/swift/ClusterAnimationStyle.swift +0 -52
- package/nitrogen/generated/shared/c++/ClusterAnimationStyle.hpp +0 -88
|
@@ -0,0 +1,80 @@
|
|
|
1
|
+
///
|
|
2
|
+
/// Func_void_UserLocationChangeEvent.kt
|
|
3
|
+
/// This file was generated by nitrogen. DO NOT MODIFY THIS FILE.
|
|
4
|
+
/// https://github.com/mrousavy/nitro
|
|
5
|
+
/// Copyright © 2026 Marc Rousavy @ Margelo
|
|
6
|
+
///
|
|
7
|
+
|
|
8
|
+
package com.margelo.nitro.nitromap
|
|
9
|
+
|
|
10
|
+
import androidx.annotation.Keep
|
|
11
|
+
import com.facebook.jni.HybridData
|
|
12
|
+
import com.facebook.proguard.annotations.DoNotStrip
|
|
13
|
+
import dalvik.annotation.optimization.FastNative
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
/**
|
|
17
|
+
* Represents the JavaScript callback `(event: struct) => void`.
|
|
18
|
+
* This can be either implemented in C++ (in which case it might be a callback coming from JS),
|
|
19
|
+
* or in Kotlin/Java (in which case it is a native callback).
|
|
20
|
+
*/
|
|
21
|
+
@DoNotStrip
|
|
22
|
+
@Keep
|
|
23
|
+
@Suppress("ClassName", "RedundantUnitReturnType")
|
|
24
|
+
fun interface Func_void_UserLocationChangeEvent: (UserLocationChangeEvent) -> Unit {
|
|
25
|
+
/**
|
|
26
|
+
* Call the given JS callback.
|
|
27
|
+
* @throws Throwable if the JS function itself throws an error, or if the JS function/runtime has already been deleted.
|
|
28
|
+
*/
|
|
29
|
+
@DoNotStrip
|
|
30
|
+
@Keep
|
|
31
|
+
override fun invoke(event: UserLocationChangeEvent): Unit
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
/**
|
|
35
|
+
* Represents the JavaScript callback `(event: struct) => void`.
|
|
36
|
+
* This is implemented in C++, via a `std::function<...>`.
|
|
37
|
+
* The callback might be coming from JS.
|
|
38
|
+
*/
|
|
39
|
+
@DoNotStrip
|
|
40
|
+
@Keep
|
|
41
|
+
@Suppress(
|
|
42
|
+
"KotlinJniMissingFunction", "unused",
|
|
43
|
+
"RedundantSuppression", "RedundantUnitReturnType", "FunctionName",
|
|
44
|
+
"ConvertSecondaryConstructorToPrimary", "ClassName", "LocalVariableName",
|
|
45
|
+
)
|
|
46
|
+
class Func_void_UserLocationChangeEvent_cxx: Func_void_UserLocationChangeEvent {
|
|
47
|
+
@DoNotStrip
|
|
48
|
+
@Keep
|
|
49
|
+
private val mHybridData: HybridData
|
|
50
|
+
|
|
51
|
+
@DoNotStrip
|
|
52
|
+
@Keep
|
|
53
|
+
private constructor(hybridData: HybridData) {
|
|
54
|
+
mHybridData = hybridData
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
@DoNotStrip
|
|
58
|
+
@Keep
|
|
59
|
+
override fun invoke(event: UserLocationChangeEvent): Unit
|
|
60
|
+
= invoke_cxx(event)
|
|
61
|
+
|
|
62
|
+
@FastNative
|
|
63
|
+
private external fun invoke_cxx(event: UserLocationChangeEvent): Unit
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
/**
|
|
67
|
+
* Represents the JavaScript callback `(event: struct) => void`.
|
|
68
|
+
* This is implemented in Java/Kotlin, via a `(UserLocationChangeEvent) -> Unit`.
|
|
69
|
+
* The callback is always coming from native.
|
|
70
|
+
*/
|
|
71
|
+
@DoNotStrip
|
|
72
|
+
@Keep
|
|
73
|
+
@Suppress("ClassName", "RedundantUnitReturnType", "unused")
|
|
74
|
+
class Func_void_UserLocationChangeEvent_java(private val function: (UserLocationChangeEvent) -> Unit): Func_void_UserLocationChangeEvent {
|
|
75
|
+
@DoNotStrip
|
|
76
|
+
@Keep
|
|
77
|
+
override fun invoke(event: UserLocationChangeEvent): Unit {
|
|
78
|
+
return this.function(event)
|
|
79
|
+
}
|
|
80
|
+
}
|
package/nitrogen/generated/android/kotlin/com/margelo/nitro/nitromap/Func_void_UserTrackingMode.kt
ADDED
|
@@ -0,0 +1,80 @@
|
|
|
1
|
+
///
|
|
2
|
+
/// Func_void_UserTrackingMode.kt
|
|
3
|
+
/// This file was generated by nitrogen. DO NOT MODIFY THIS FILE.
|
|
4
|
+
/// https://github.com/mrousavy/nitro
|
|
5
|
+
/// Copyright © 2026 Marc Rousavy @ Margelo
|
|
6
|
+
///
|
|
7
|
+
|
|
8
|
+
package com.margelo.nitro.nitromap
|
|
9
|
+
|
|
10
|
+
import androidx.annotation.Keep
|
|
11
|
+
import com.facebook.jni.HybridData
|
|
12
|
+
import com.facebook.proguard.annotations.DoNotStrip
|
|
13
|
+
import dalvik.annotation.optimization.FastNative
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
/**
|
|
17
|
+
* Represents the JavaScript callback `(mode: enum) => void`.
|
|
18
|
+
* This can be either implemented in C++ (in which case it might be a callback coming from JS),
|
|
19
|
+
* or in Kotlin/Java (in which case it is a native callback).
|
|
20
|
+
*/
|
|
21
|
+
@DoNotStrip
|
|
22
|
+
@Keep
|
|
23
|
+
@Suppress("ClassName", "RedundantUnitReturnType")
|
|
24
|
+
fun interface Func_void_UserTrackingMode: (UserTrackingMode) -> Unit {
|
|
25
|
+
/**
|
|
26
|
+
* Call the given JS callback.
|
|
27
|
+
* @throws Throwable if the JS function itself throws an error, or if the JS function/runtime has already been deleted.
|
|
28
|
+
*/
|
|
29
|
+
@DoNotStrip
|
|
30
|
+
@Keep
|
|
31
|
+
override fun invoke(mode: UserTrackingMode): Unit
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
/**
|
|
35
|
+
* Represents the JavaScript callback `(mode: enum) => void`.
|
|
36
|
+
* This is implemented in C++, via a `std::function<...>`.
|
|
37
|
+
* The callback might be coming from JS.
|
|
38
|
+
*/
|
|
39
|
+
@DoNotStrip
|
|
40
|
+
@Keep
|
|
41
|
+
@Suppress(
|
|
42
|
+
"KotlinJniMissingFunction", "unused",
|
|
43
|
+
"RedundantSuppression", "RedundantUnitReturnType", "FunctionName",
|
|
44
|
+
"ConvertSecondaryConstructorToPrimary", "ClassName", "LocalVariableName",
|
|
45
|
+
)
|
|
46
|
+
class Func_void_UserTrackingMode_cxx: Func_void_UserTrackingMode {
|
|
47
|
+
@DoNotStrip
|
|
48
|
+
@Keep
|
|
49
|
+
private val mHybridData: HybridData
|
|
50
|
+
|
|
51
|
+
@DoNotStrip
|
|
52
|
+
@Keep
|
|
53
|
+
private constructor(hybridData: HybridData) {
|
|
54
|
+
mHybridData = hybridData
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
@DoNotStrip
|
|
58
|
+
@Keep
|
|
59
|
+
override fun invoke(mode: UserTrackingMode): Unit
|
|
60
|
+
= invoke_cxx(mode)
|
|
61
|
+
|
|
62
|
+
@FastNative
|
|
63
|
+
private external fun invoke_cxx(mode: UserTrackingMode): Unit
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
/**
|
|
67
|
+
* Represents the JavaScript callback `(mode: enum) => void`.
|
|
68
|
+
* This is implemented in Java/Kotlin, via a `(UserTrackingMode) -> Unit`.
|
|
69
|
+
* The callback is always coming from native.
|
|
70
|
+
*/
|
|
71
|
+
@DoNotStrip
|
|
72
|
+
@Keep
|
|
73
|
+
@Suppress("ClassName", "RedundantUnitReturnType", "unused")
|
|
74
|
+
class Func_void_UserTrackingMode_java(private val function: (UserTrackingMode) -> Unit): Func_void_UserTrackingMode {
|
|
75
|
+
@DoNotStrip
|
|
76
|
+
@Keep
|
|
77
|
+
override fun invoke(mode: UserTrackingMode): Unit {
|
|
78
|
+
return this.function(mode)
|
|
79
|
+
}
|
|
80
|
+
}
|
|
@@ -0,0 +1,80 @@
|
|
|
1
|
+
///
|
|
2
|
+
/// Func_void_std__string.kt
|
|
3
|
+
/// This file was generated by nitrogen. DO NOT MODIFY THIS FILE.
|
|
4
|
+
/// https://github.com/mrousavy/nitro
|
|
5
|
+
/// Copyright © 2026 Marc Rousavy @ Margelo
|
|
6
|
+
///
|
|
7
|
+
|
|
8
|
+
package com.margelo.nitro.nitromap
|
|
9
|
+
|
|
10
|
+
import androidx.annotation.Keep
|
|
11
|
+
import com.facebook.jni.HybridData
|
|
12
|
+
import com.facebook.proguard.annotations.DoNotStrip
|
|
13
|
+
import dalvik.annotation.optimization.FastNative
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
/**
|
|
17
|
+
* Represents the JavaScript callback `(id: string) => void`.
|
|
18
|
+
* This can be either implemented in C++ (in which case it might be a callback coming from JS),
|
|
19
|
+
* or in Kotlin/Java (in which case it is a native callback).
|
|
20
|
+
*/
|
|
21
|
+
@DoNotStrip
|
|
22
|
+
@Keep
|
|
23
|
+
@Suppress("ClassName", "RedundantUnitReturnType")
|
|
24
|
+
fun interface Func_void_std__string: (String) -> Unit {
|
|
25
|
+
/**
|
|
26
|
+
* Call the given JS callback.
|
|
27
|
+
* @throws Throwable if the JS function itself throws an error, or if the JS function/runtime has already been deleted.
|
|
28
|
+
*/
|
|
29
|
+
@DoNotStrip
|
|
30
|
+
@Keep
|
|
31
|
+
override fun invoke(id: String): Unit
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
/**
|
|
35
|
+
* Represents the JavaScript callback `(id: string) => void`.
|
|
36
|
+
* This is implemented in C++, via a `std::function<...>`.
|
|
37
|
+
* The callback might be coming from JS.
|
|
38
|
+
*/
|
|
39
|
+
@DoNotStrip
|
|
40
|
+
@Keep
|
|
41
|
+
@Suppress(
|
|
42
|
+
"KotlinJniMissingFunction", "unused",
|
|
43
|
+
"RedundantSuppression", "RedundantUnitReturnType", "FunctionName",
|
|
44
|
+
"ConvertSecondaryConstructorToPrimary", "ClassName", "LocalVariableName",
|
|
45
|
+
)
|
|
46
|
+
class Func_void_std__string_cxx: Func_void_std__string {
|
|
47
|
+
@DoNotStrip
|
|
48
|
+
@Keep
|
|
49
|
+
private val mHybridData: HybridData
|
|
50
|
+
|
|
51
|
+
@DoNotStrip
|
|
52
|
+
@Keep
|
|
53
|
+
private constructor(hybridData: HybridData) {
|
|
54
|
+
mHybridData = hybridData
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
@DoNotStrip
|
|
58
|
+
@Keep
|
|
59
|
+
override fun invoke(id: String): Unit
|
|
60
|
+
= invoke_cxx(id)
|
|
61
|
+
|
|
62
|
+
@FastNative
|
|
63
|
+
private external fun invoke_cxx(id: String): Unit
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
/**
|
|
67
|
+
* Represents the JavaScript callback `(id: string) => void`.
|
|
68
|
+
* This is implemented in Java/Kotlin, via a `(String) -> Unit`.
|
|
69
|
+
* The callback is always coming from native.
|
|
70
|
+
*/
|
|
71
|
+
@DoNotStrip
|
|
72
|
+
@Keep
|
|
73
|
+
@Suppress("ClassName", "RedundantUnitReturnType", "unused")
|
|
74
|
+
class Func_void_std__string_java(private val function: (String) -> Unit): Func_void_std__string {
|
|
75
|
+
@DoNotStrip
|
|
76
|
+
@Keep
|
|
77
|
+
override fun invoke(id: String): Unit {
|
|
78
|
+
return this.function(id)
|
|
79
|
+
}
|
|
80
|
+
}
|
|
@@ -55,6 +55,12 @@ abstract class HybridNitroMapSpec: HybridView() {
|
|
|
55
55
|
@set:Keep
|
|
56
56
|
abstract var initialRegion: Region?
|
|
57
57
|
|
|
58
|
+
@get:DoNotStrip
|
|
59
|
+
@get:Keep
|
|
60
|
+
@set:DoNotStrip
|
|
61
|
+
@set:Keep
|
|
62
|
+
abstract var region: Region?
|
|
63
|
+
|
|
58
64
|
@get:DoNotStrip
|
|
59
65
|
@get:Keep
|
|
60
66
|
@set:DoNotStrip
|
|
@@ -101,13 +107,43 @@ abstract class HybridNitroMapSpec: HybridView() {
|
|
|
101
107
|
@get:Keep
|
|
102
108
|
@set:DoNotStrip
|
|
103
109
|
@set:Keep
|
|
104
|
-
abstract var
|
|
110
|
+
abstract var clusterConfig: ClusterConfig?
|
|
105
111
|
|
|
106
112
|
@get:DoNotStrip
|
|
107
113
|
@get:Keep
|
|
108
114
|
@set:DoNotStrip
|
|
109
115
|
@set:Keep
|
|
110
|
-
abstract var
|
|
116
|
+
abstract var mapPadding: EdgePadding
|
|
117
|
+
|
|
118
|
+
@get:DoNotStrip
|
|
119
|
+
@get:Keep
|
|
120
|
+
@set:DoNotStrip
|
|
121
|
+
@set:Keep
|
|
122
|
+
abstract var showsTraffic: Boolean?
|
|
123
|
+
|
|
124
|
+
@get:DoNotStrip
|
|
125
|
+
@get:Keep
|
|
126
|
+
@set:DoNotStrip
|
|
127
|
+
@set:Keep
|
|
128
|
+
abstract var showsBuildings: Boolean?
|
|
129
|
+
|
|
130
|
+
@get:DoNotStrip
|
|
131
|
+
@get:Keep
|
|
132
|
+
@set:DoNotStrip
|
|
133
|
+
@set:Keep
|
|
134
|
+
abstract var showsCompass: Boolean?
|
|
135
|
+
|
|
136
|
+
@get:DoNotStrip
|
|
137
|
+
@get:Keep
|
|
138
|
+
@set:DoNotStrip
|
|
139
|
+
@set:Keep
|
|
140
|
+
abstract var minZoom: Double
|
|
141
|
+
|
|
142
|
+
@get:DoNotStrip
|
|
143
|
+
@get:Keep
|
|
144
|
+
@set:DoNotStrip
|
|
145
|
+
@set:Keep
|
|
146
|
+
abstract var maxZoom: Double
|
|
111
147
|
|
|
112
148
|
@get:DoNotStrip
|
|
113
149
|
@get:Keep
|
|
@@ -115,6 +151,30 @@ abstract class HybridNitroMapSpec: HybridView() {
|
|
|
115
151
|
@set:Keep
|
|
116
152
|
abstract var darkMode: Boolean?
|
|
117
153
|
|
|
154
|
+
@get:DoNotStrip
|
|
155
|
+
@get:Keep
|
|
156
|
+
@set:DoNotStrip
|
|
157
|
+
@set:Keep
|
|
158
|
+
abstract var userTrackingMode: UserTrackingMode?
|
|
159
|
+
|
|
160
|
+
@get:DoNotStrip
|
|
161
|
+
@get:Keep
|
|
162
|
+
@set:DoNotStrip
|
|
163
|
+
@set:Keep
|
|
164
|
+
abstract var userLocationImage: String
|
|
165
|
+
|
|
166
|
+
@get:DoNotStrip
|
|
167
|
+
@get:Keep
|
|
168
|
+
@set:DoNotStrip
|
|
169
|
+
@set:Keep
|
|
170
|
+
abstract var userLocationSize: Double
|
|
171
|
+
|
|
172
|
+
@get:DoNotStrip
|
|
173
|
+
@get:Keep
|
|
174
|
+
@set:DoNotStrip
|
|
175
|
+
@set:Keep
|
|
176
|
+
abstract var userLocationAnchor: Point?
|
|
177
|
+
|
|
118
178
|
abstract var onPress: ((event: MapPressEvent) -> Unit)?
|
|
119
179
|
|
|
120
180
|
private var onPress_cxx: Func_void_MapPressEvent?
|
|
@@ -255,6 +315,48 @@ abstract class HybridNitroMapSpec: HybridView() {
|
|
|
255
315
|
onClusterPress = value?.let { it }
|
|
256
316
|
}
|
|
257
317
|
|
|
318
|
+
abstract var onPolylinePress: ((id: String) -> Unit)?
|
|
319
|
+
|
|
320
|
+
private var onPolylinePress_cxx: Func_void_std__string?
|
|
321
|
+
@Keep
|
|
322
|
+
@DoNotStrip
|
|
323
|
+
get() {
|
|
324
|
+
return onPolylinePress?.let { Func_void_std__string_java(it) }
|
|
325
|
+
}
|
|
326
|
+
@Keep
|
|
327
|
+
@DoNotStrip
|
|
328
|
+
set(value) {
|
|
329
|
+
onPolylinePress = value?.let { it }
|
|
330
|
+
}
|
|
331
|
+
|
|
332
|
+
abstract var onPolygonPress: ((id: String) -> Unit)?
|
|
333
|
+
|
|
334
|
+
private var onPolygonPress_cxx: Func_void_std__string?
|
|
335
|
+
@Keep
|
|
336
|
+
@DoNotStrip
|
|
337
|
+
get() {
|
|
338
|
+
return onPolygonPress?.let { Func_void_std__string_java(it) }
|
|
339
|
+
}
|
|
340
|
+
@Keep
|
|
341
|
+
@DoNotStrip
|
|
342
|
+
set(value) {
|
|
343
|
+
onPolygonPress = value?.let { it }
|
|
344
|
+
}
|
|
345
|
+
|
|
346
|
+
abstract var onCirclePress: ((id: String) -> Unit)?
|
|
347
|
+
|
|
348
|
+
private var onCirclePress_cxx: Func_void_std__string?
|
|
349
|
+
@Keep
|
|
350
|
+
@DoNotStrip
|
|
351
|
+
get() {
|
|
352
|
+
return onCirclePress?.let { Func_void_std__string_java(it) }
|
|
353
|
+
}
|
|
354
|
+
@Keep
|
|
355
|
+
@DoNotStrip
|
|
356
|
+
set(value) {
|
|
357
|
+
onCirclePress = value?.let { it }
|
|
358
|
+
}
|
|
359
|
+
|
|
258
360
|
abstract var onError: ((error: MapError) -> Unit)?
|
|
259
361
|
|
|
260
362
|
private var onError_cxx: Func_void_MapError?
|
|
@@ -268,6 +370,62 @@ abstract class HybridNitroMapSpec: HybridView() {
|
|
|
268
370
|
set(value) {
|
|
269
371
|
onError = value?.let { it }
|
|
270
372
|
}
|
|
373
|
+
|
|
374
|
+
abstract var onUserLocationChange: ((event: UserLocationChangeEvent) -> Unit)?
|
|
375
|
+
|
|
376
|
+
private var onUserLocationChange_cxx: Func_void_UserLocationChangeEvent?
|
|
377
|
+
@Keep
|
|
378
|
+
@DoNotStrip
|
|
379
|
+
get() {
|
|
380
|
+
return onUserLocationChange?.let { Func_void_UserLocationChangeEvent_java(it) }
|
|
381
|
+
}
|
|
382
|
+
@Keep
|
|
383
|
+
@DoNotStrip
|
|
384
|
+
set(value) {
|
|
385
|
+
onUserLocationChange = value?.let { it }
|
|
386
|
+
}
|
|
387
|
+
|
|
388
|
+
abstract var onUserTrackingModeChange: ((mode: UserTrackingMode) -> Unit)?
|
|
389
|
+
|
|
390
|
+
private var onUserTrackingModeChange_cxx: Func_void_UserTrackingMode?
|
|
391
|
+
@Keep
|
|
392
|
+
@DoNotStrip
|
|
393
|
+
get() {
|
|
394
|
+
return onUserTrackingModeChange?.let { Func_void_UserTrackingMode_java(it) }
|
|
395
|
+
}
|
|
396
|
+
@Keep
|
|
397
|
+
@DoNotStrip
|
|
398
|
+
set(value) {
|
|
399
|
+
onUserTrackingModeChange = value?.let { it }
|
|
400
|
+
}
|
|
401
|
+
|
|
402
|
+
abstract var onUserLocationError: ((error: MapError) -> Unit)?
|
|
403
|
+
|
|
404
|
+
private var onUserLocationError_cxx: Func_void_MapError?
|
|
405
|
+
@Keep
|
|
406
|
+
@DoNotStrip
|
|
407
|
+
get() {
|
|
408
|
+
return onUserLocationError?.let { Func_void_MapError_java(it) }
|
|
409
|
+
}
|
|
410
|
+
@Keep
|
|
411
|
+
@DoNotStrip
|
|
412
|
+
set(value) {
|
|
413
|
+
onUserLocationError = value?.let { it }
|
|
414
|
+
}
|
|
415
|
+
|
|
416
|
+
abstract var onMapIdle: (() -> Unit)?
|
|
417
|
+
|
|
418
|
+
private var onMapIdle_cxx: Func_void?
|
|
419
|
+
@Keep
|
|
420
|
+
@DoNotStrip
|
|
421
|
+
get() {
|
|
422
|
+
return onMapIdle?.let { Func_void_java(it) }
|
|
423
|
+
}
|
|
424
|
+
@Keep
|
|
425
|
+
@DoNotStrip
|
|
426
|
+
set(value) {
|
|
427
|
+
onMapIdle = value?.let { it }
|
|
428
|
+
}
|
|
271
429
|
|
|
272
430
|
// Methods
|
|
273
431
|
@DoNotStrip
|
|
@@ -278,6 +436,10 @@ abstract class HybridNitroMapSpec: HybridView() {
|
|
|
278
436
|
@Keep
|
|
279
437
|
abstract fun fitToCoordinates(coordinates: Array<Coordinate>, edgePadding: EdgePadding?, animated: Boolean?): Unit
|
|
280
438
|
|
|
439
|
+
@DoNotStrip
|
|
440
|
+
@Keep
|
|
441
|
+
abstract fun fitToSuppliedMarkers(markerIds: Array<String>, edgePadding: EdgePadding?, animated: Boolean?): Unit
|
|
442
|
+
|
|
281
443
|
@DoNotStrip
|
|
282
444
|
@Keep
|
|
283
445
|
abstract fun animateCamera(camera: Camera, duration: Double?): Unit
|
|
@@ -298,6 +460,18 @@ abstract class HybridNitroMapSpec: HybridView() {
|
|
|
298
460
|
@Keep
|
|
299
461
|
abstract fun getMapBoundaries(): Promise<MapBoundaries>
|
|
300
462
|
|
|
463
|
+
@DoNotStrip
|
|
464
|
+
@Keep
|
|
465
|
+
abstract fun centerOnUserLocation(): Unit
|
|
466
|
+
|
|
467
|
+
@DoNotStrip
|
|
468
|
+
@Keep
|
|
469
|
+
abstract fun pointForCoordinate(coordinate: Coordinate): Point
|
|
470
|
+
|
|
471
|
+
@DoNotStrip
|
|
472
|
+
@Keep
|
|
473
|
+
abstract fun coordinateForPoint(point: Point): Coordinate
|
|
474
|
+
|
|
301
475
|
@DoNotStrip
|
|
302
476
|
@Keep
|
|
303
477
|
abstract fun setIsDarkMode(enabled: Boolean): Unit
|
|
@@ -322,6 +496,10 @@ abstract class HybridNitroMapSpec: HybridView() {
|
|
|
322
496
|
@Keep
|
|
323
497
|
abstract fun selectMarker(id: String): Unit
|
|
324
498
|
|
|
499
|
+
@DoNotStrip
|
|
500
|
+
@Keep
|
|
501
|
+
abstract fun deselectMarker(): Unit
|
|
502
|
+
|
|
325
503
|
@DoNotStrip
|
|
326
504
|
@Keep
|
|
327
505
|
abstract fun clearMarkers(): Unit
|
|
@@ -333,6 +511,54 @@ abstract class HybridNitroMapSpec: HybridView() {
|
|
|
333
511
|
@DoNotStrip
|
|
334
512
|
@Keep
|
|
335
513
|
abstract fun refreshClusters(): Unit
|
|
514
|
+
|
|
515
|
+
@DoNotStrip
|
|
516
|
+
@Keep
|
|
517
|
+
abstract fun addPolyline(polyline: PolylineData): Unit
|
|
518
|
+
|
|
519
|
+
@DoNotStrip
|
|
520
|
+
@Keep
|
|
521
|
+
abstract fun updatePolyline(polyline: PolylineData): Unit
|
|
522
|
+
|
|
523
|
+
@DoNotStrip
|
|
524
|
+
@Keep
|
|
525
|
+
abstract fun removePolyline(id: String): Unit
|
|
526
|
+
|
|
527
|
+
@DoNotStrip
|
|
528
|
+
@Keep
|
|
529
|
+
abstract fun clearPolylines(): Unit
|
|
530
|
+
|
|
531
|
+
@DoNotStrip
|
|
532
|
+
@Keep
|
|
533
|
+
abstract fun addPolygon(polygon: PolygonData): Unit
|
|
534
|
+
|
|
535
|
+
@DoNotStrip
|
|
536
|
+
@Keep
|
|
537
|
+
abstract fun updatePolygon(polygon: PolygonData): Unit
|
|
538
|
+
|
|
539
|
+
@DoNotStrip
|
|
540
|
+
@Keep
|
|
541
|
+
abstract fun removePolygon(id: String): Unit
|
|
542
|
+
|
|
543
|
+
@DoNotStrip
|
|
544
|
+
@Keep
|
|
545
|
+
abstract fun clearPolygons(): Unit
|
|
546
|
+
|
|
547
|
+
@DoNotStrip
|
|
548
|
+
@Keep
|
|
549
|
+
abstract fun addCircle(circle: CircleData): Unit
|
|
550
|
+
|
|
551
|
+
@DoNotStrip
|
|
552
|
+
@Keep
|
|
553
|
+
abstract fun updateCircle(circle: CircleData): Unit
|
|
554
|
+
|
|
555
|
+
@DoNotStrip
|
|
556
|
+
@Keep
|
|
557
|
+
abstract fun removeCircle(id: String): Unit
|
|
558
|
+
|
|
559
|
+
@DoNotStrip
|
|
560
|
+
@Keep
|
|
561
|
+
abstract fun clearCircles(): Unit
|
|
336
562
|
|
|
337
563
|
private external fun initHybrid(): HybridData
|
|
338
564
|
|
|
@@ -49,10 +49,19 @@ data class MarkerData(
|
|
|
49
49
|
val config: MarkerConfig,
|
|
50
50
|
@DoNotStrip
|
|
51
51
|
@Keep
|
|
52
|
+
val accessibilityLabel: String?,
|
|
53
|
+
@DoNotStrip
|
|
54
|
+
@Keep
|
|
52
55
|
val clusteringEnabled: Boolean,
|
|
53
56
|
@DoNotStrip
|
|
54
57
|
@Keep
|
|
55
|
-
val animation: MarkerAnimation
|
|
58
|
+
val animation: MarkerAnimation,
|
|
59
|
+
@DoNotStrip
|
|
60
|
+
@Keep
|
|
61
|
+
val animationDuration: Double,
|
|
62
|
+
@DoNotStrip
|
|
63
|
+
@Keep
|
|
64
|
+
val animateOnReappear: Boolean
|
|
56
65
|
) {
|
|
57
66
|
/* primary constructor */
|
|
58
67
|
|
|
@@ -64,8 +73,8 @@ data class MarkerData(
|
|
|
64
73
|
@Keep
|
|
65
74
|
@Suppress("unused")
|
|
66
75
|
@JvmStatic
|
|
67
|
-
private fun fromCpp(id: String, coordinate: Coordinate, title: String?, description: String?, draggable: Boolean, opacity: Double, rotation: Double, zIndex: Double, anchor: Point, config: MarkerConfig, clusteringEnabled: Boolean, animation: MarkerAnimation): MarkerData {
|
|
68
|
-
return MarkerData(id, coordinate, title, description, draggable, opacity, rotation, zIndex, anchor, config, clusteringEnabled, animation)
|
|
76
|
+
private fun fromCpp(id: String, coordinate: Coordinate, title: String?, description: String?, draggable: Boolean, opacity: Double, rotation: Double, zIndex: Double, anchor: Point, config: MarkerConfig, accessibilityLabel: String?, clusteringEnabled: Boolean, animation: MarkerAnimation, animationDuration: Double, animateOnReappear: Boolean): MarkerData {
|
|
77
|
+
return MarkerData(id, coordinate, title, description, draggable, opacity, rotation, zIndex, anchor, config, accessibilityLabel, clusteringEnabled, animation, animationDuration, animateOnReappear)
|
|
69
78
|
}
|
|
70
79
|
}
|
|
71
80
|
}
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
///
|
|
2
|
+
/// PolygonData.kt
|
|
3
|
+
/// This file was generated by nitrogen. DO NOT MODIFY THIS FILE.
|
|
4
|
+
/// https://github.com/mrousavy/nitro
|
|
5
|
+
/// Copyright © 2026 Marc Rousavy @ Margelo
|
|
6
|
+
///
|
|
7
|
+
|
|
8
|
+
package com.margelo.nitro.nitromap
|
|
9
|
+
|
|
10
|
+
import androidx.annotation.Keep
|
|
11
|
+
import com.facebook.proguard.annotations.DoNotStrip
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
/**
|
|
15
|
+
* Represents the JavaScript object/struct "PolygonData".
|
|
16
|
+
*/
|
|
17
|
+
@DoNotStrip
|
|
18
|
+
@Keep
|
|
19
|
+
data class PolygonData(
|
|
20
|
+
@DoNotStrip
|
|
21
|
+
@Keep
|
|
22
|
+
val id: String,
|
|
23
|
+
@DoNotStrip
|
|
24
|
+
@Keep
|
|
25
|
+
val coordinates: Array<Coordinate>,
|
|
26
|
+
@DoNotStrip
|
|
27
|
+
@Keep
|
|
28
|
+
val holes: Array<Array<Coordinate>>,
|
|
29
|
+
@DoNotStrip
|
|
30
|
+
@Keep
|
|
31
|
+
val fillColor: MarkerColor,
|
|
32
|
+
@DoNotStrip
|
|
33
|
+
@Keep
|
|
34
|
+
val strokeColor: MarkerColor,
|
|
35
|
+
@DoNotStrip
|
|
36
|
+
@Keep
|
|
37
|
+
val strokeWidth: Double,
|
|
38
|
+
@DoNotStrip
|
|
39
|
+
@Keep
|
|
40
|
+
val zIndex: Double,
|
|
41
|
+
@DoNotStrip
|
|
42
|
+
@Keep
|
|
43
|
+
val tappable: Boolean,
|
|
44
|
+
@DoNotStrip
|
|
45
|
+
@Keep
|
|
46
|
+
val accessibilityLabel: String?
|
|
47
|
+
) {
|
|
48
|
+
/* primary constructor */
|
|
49
|
+
|
|
50
|
+
private companion object {
|
|
51
|
+
/**
|
|
52
|
+
* Constructor called from C++
|
|
53
|
+
*/
|
|
54
|
+
@DoNotStrip
|
|
55
|
+
@Keep
|
|
56
|
+
@Suppress("unused")
|
|
57
|
+
@JvmStatic
|
|
58
|
+
private fun fromCpp(id: String, coordinates: Array<Coordinate>, holes: Array<Array<Coordinate>>, fillColor: MarkerColor, strokeColor: MarkerColor, strokeWidth: Double, zIndex: Double, tappable: Boolean, accessibilityLabel: String?): PolygonData {
|
|
59
|
+
return PolygonData(id, coordinates, holes, fillColor, strokeColor, strokeWidth, zIndex, tappable, accessibilityLabel)
|
|
60
|
+
}
|
|
61
|
+
}
|
|
62
|
+
}
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
///
|
|
2
|
+
/// PolylineData.kt
|
|
3
|
+
/// This file was generated by nitrogen. DO NOT MODIFY THIS FILE.
|
|
4
|
+
/// https://github.com/mrousavy/nitro
|
|
5
|
+
/// Copyright © 2026 Marc Rousavy @ Margelo
|
|
6
|
+
///
|
|
7
|
+
|
|
8
|
+
package com.margelo.nitro.nitromap
|
|
9
|
+
|
|
10
|
+
import androidx.annotation.Keep
|
|
11
|
+
import com.facebook.proguard.annotations.DoNotStrip
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
/**
|
|
15
|
+
* Represents the JavaScript object/struct "PolylineData".
|
|
16
|
+
*/
|
|
17
|
+
@DoNotStrip
|
|
18
|
+
@Keep
|
|
19
|
+
data class PolylineData(
|
|
20
|
+
@DoNotStrip
|
|
21
|
+
@Keep
|
|
22
|
+
val id: String,
|
|
23
|
+
@DoNotStrip
|
|
24
|
+
@Keep
|
|
25
|
+
val coordinates: Array<Coordinate>,
|
|
26
|
+
@DoNotStrip
|
|
27
|
+
@Keep
|
|
28
|
+
val strokeColor: MarkerColor,
|
|
29
|
+
@DoNotStrip
|
|
30
|
+
@Keep
|
|
31
|
+
val strokeWidth: Double,
|
|
32
|
+
@DoNotStrip
|
|
33
|
+
@Keep
|
|
34
|
+
val geodesic: Boolean,
|
|
35
|
+
@DoNotStrip
|
|
36
|
+
@Keep
|
|
37
|
+
val dashed: Boolean,
|
|
38
|
+
@DoNotStrip
|
|
39
|
+
@Keep
|
|
40
|
+
val zIndex: Double,
|
|
41
|
+
@DoNotStrip
|
|
42
|
+
@Keep
|
|
43
|
+
val tappable: Boolean,
|
|
44
|
+
@DoNotStrip
|
|
45
|
+
@Keep
|
|
46
|
+
val accessibilityLabel: String?
|
|
47
|
+
) {
|
|
48
|
+
/* primary constructor */
|
|
49
|
+
|
|
50
|
+
private companion object {
|
|
51
|
+
/**
|
|
52
|
+
* Constructor called from C++
|
|
53
|
+
*/
|
|
54
|
+
@DoNotStrip
|
|
55
|
+
@Keep
|
|
56
|
+
@Suppress("unused")
|
|
57
|
+
@JvmStatic
|
|
58
|
+
private fun fromCpp(id: String, coordinates: Array<Coordinate>, strokeColor: MarkerColor, strokeWidth: Double, geodesic: Boolean, dashed: Boolean, zIndex: Double, tappable: Boolean, accessibilityLabel: String?): PolylineData {
|
|
59
|
+
return PolylineData(id, coordinates, strokeColor, strokeWidth, geodesic, dashed, zIndex, tappable, accessibilityLabel)
|
|
60
|
+
}
|
|
61
|
+
}
|
|
62
|
+
}
|