react-native-google-maps-plus 1.3.0 → 1.4.1-dev.1
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/android/build.gradle +1 -1
- package/android/src/main/java/com/rngooglemapsplus/GoogleMapsViewImpl.kt +50 -161
- package/android/src/main/java/com/rngooglemapsplus/LocationHandler.kt +38 -36
- package/android/src/main/java/com/rngooglemapsplus/MapCircleBuilder.kt +33 -9
- package/android/src/main/java/com/rngooglemapsplus/MapMarkerBuilder.kt +73 -18
- package/android/src/main/java/com/rngooglemapsplus/MapPolygonBuilder.kt +59 -12
- package/android/src/main/java/com/rngooglemapsplus/MapPolylineBuilder.kt.kt +47 -12
- package/android/src/main/java/com/rngooglemapsplus/RNGoogleMapsPlusView.kt +12 -9
- package/android/src/main/java/com/rngooglemapsplus/extensions/CameraPositionExtension.kt +12 -0
- package/android/src/main/java/com/rngooglemapsplus/extensions/IntExtension.kt +28 -0
- package/android/src/main/java/com/rngooglemapsplus/extensions/LatLngBounds.kt +15 -0
- package/android/src/main/java/com/rngooglemapsplus/extensions/LatLngExtension.kt +6 -0
- package/android/src/main/java/com/rngooglemapsplus/extensions/LocationExtension.kt +59 -0
- package/android/src/main/java/com/rngooglemapsplus/extensions/RNCameraExtension.kt +1 -2
- package/android/src/main/java/com/rngooglemapsplus/extensions/RNLatLngExtension.kt +6 -0
- package/android/src/main/java/com/rngooglemapsplus/extensions/RNMarkerExtension.kt +8 -0
- package/android/src/main/java/com/rngooglemapsplus/extensions/RNPolygonExtension.kt +2 -0
- package/android/src/main/java/com/rngooglemapsplus/extensions/RNPolylineExtension.kt +1 -0
- package/ios/GoogleMapViewImpl.swift +39 -180
- package/ios/LocationHandler.swift +5 -13
- package/ios/MapCircleBuilder.swift +30 -18
- package/ios/MapHelper.swift +20 -0
- package/ios/MapMarkerBuilder.swift +105 -86
- package/ios/MapPolygonBuilder.swift +62 -13
- package/ios/MapPolylineBuilder.swift +33 -15
- package/ios/RNGoogleMapsPlusView.swift +15 -9
- package/ios/extensions/CLError+Extension.swift +14 -0
- package/ios/extensions/CLLocation+Extension.swift +27 -0
- package/ios/extensions/CLLocationCoordinate2D+Extension.swift +7 -0
- package/ios/extensions/GMSCameraPosition+Extension.swift +12 -0
- package/ios/extensions/GMSCoordinateBounds+Extension.swift +19 -0
- package/ios/extensions/RNLatLng+Extension.swift +7 -0
- package/ios/extensions/RNMarker+Extension.swift +7 -3
- package/ios/extensions/RNPolygon+Extension.swift.swift +16 -1
- package/ios/extensions/RNPolyline+Extension.swift.swift +1 -0
- package/lib/module/GoogleMapsPlus.js +7 -0
- package/lib/module/GoogleMapsPlus.js.map +1 -0
- package/lib/module/index.js +3 -5
- package/lib/module/index.js.map +1 -1
- package/lib/module/types.js.map +1 -1
- package/lib/nitrogen/generated/shared/json/RNGoogleMapsPlusViewConfig.json +44 -0
- package/lib/typescript/src/GoogleMapsPlus.d.ts +5 -0
- package/lib/typescript/src/GoogleMapsPlus.d.ts.map +1 -0
- package/lib/typescript/src/index.d.ts +3 -3
- package/lib/typescript/src/index.d.ts.map +1 -1
- package/lib/typescript/src/types.d.ts +33 -0
- package/lib/typescript/src/types.d.ts.map +1 -1
- package/nitrogen/generated/android/c++/JFunc_void_RNLocation.hpp +6 -0
- package/nitrogen/generated/android/c++/JHybridRNGoogleMapsPlusViewSpec.cpp +12 -0
- package/nitrogen/generated/android/c++/JRNLocation.hpp +32 -2
- package/nitrogen/generated/android/c++/JRNLocationAndroid.hpp +82 -0
- package/nitrogen/generated/android/c++/JRNLocationIOS.hpp +77 -0
- package/nitrogen/generated/android/c++/JRNMarker.hpp +8 -0
- package/nitrogen/generated/android/c++/JRNPolygon.hpp +29 -2
- package/nitrogen/generated/android/c++/JRNPolygonHole.hpp +72 -0
- package/nitrogen/generated/android/c++/JRNPolyline.hpp +4 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rngooglemapsplus/RNLocation.kt +19 -1
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rngooglemapsplus/RNLocationAndroid.kt +50 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rngooglemapsplus/RNLocationIOS.kt +47 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rngooglemapsplus/RNMarker.kt +6 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rngooglemapsplus/RNPolygon.kt +7 -1
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rngooglemapsplus/RNPolygonHole.kt +29 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rngooglemapsplus/RNPolyline.kt +3 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/rngooglemapsplus/views/HybridRNGoogleMapsPlusViewManager.kt +8 -3
- package/nitrogen/generated/ios/RNGoogleMapsPlus-Swift-Cxx-Bridge.cpp +16 -16
- package/nitrogen/generated/ios/RNGoogleMapsPlus-Swift-Cxx-Bridge.hpp +87 -20
- package/nitrogen/generated/ios/RNGoogleMapsPlus-Swift-Cxx-Umbrella.hpp +9 -0
- package/nitrogen/generated/ios/c++/HybridRNGoogleMapsPlusViewSpecSwift.hpp +12 -3
- package/nitrogen/generated/ios/c++/views/HybridRNGoogleMapsPlusViewComponent.mm +8 -0
- package/nitrogen/generated/ios/swift/HybridRNGoogleMapsPlusViewSpec_cxx.swift +7 -56
- package/nitrogen/generated/ios/swift/RNCamera.swift +1 -8
- package/nitrogen/generated/ios/swift/RNHeatmap.swift +1 -8
- package/nitrogen/generated/ios/swift/RNHeatmapGradient.swift +11 -15
- package/nitrogen/generated/ios/swift/RNInitialProps.swift +1 -8
- package/nitrogen/generated/ios/swift/RNLocation.swift +92 -2
- package/nitrogen/generated/ios/swift/RNLocationAndroid.swift +215 -0
- package/nitrogen/generated/ios/swift/RNLocationConfig.swift +2 -16
- package/nitrogen/generated/ios/swift/RNLocationIOS.swift +185 -0
- package/nitrogen/generated/ios/swift/RNMarker.swift +47 -15
- package/nitrogen/generated/ios/swift/RNPolygon.swift +66 -1
- package/nitrogen/generated/ios/swift/RNPolygonHole.swift +47 -0
- package/nitrogen/generated/ios/swift/RNPolyline.swift +24 -1
- package/nitrogen/generated/ios/swift/RNSnapshotOptions.swift +1 -8
- package/nitrogen/generated/shared/c++/RNAndroidLocationConfig.hpp +8 -0
- package/nitrogen/generated/shared/c++/RNCamera.hpp +8 -0
- package/nitrogen/generated/shared/c++/RNCircle.hpp +8 -0
- package/nitrogen/generated/shared/c++/RNHeatmap.hpp +8 -0
- package/nitrogen/generated/shared/c++/RNHeatmapGradient.hpp +8 -0
- package/nitrogen/generated/shared/c++/RNHeatmapPoint.hpp +8 -0
- package/nitrogen/generated/shared/c++/RNIOSLocationConfig.hpp +8 -0
- package/nitrogen/generated/shared/c++/RNIndoorBuilding.hpp +8 -0
- package/nitrogen/generated/shared/c++/RNIndoorLevel.hpp +8 -0
- package/nitrogen/generated/shared/c++/RNInitialProps.hpp +8 -0
- package/nitrogen/generated/shared/c++/RNKMLayer.hpp +8 -0
- package/nitrogen/generated/shared/c++/RNLatLng.hpp +8 -0
- package/nitrogen/generated/shared/c++/RNLatLngBounds.hpp +8 -0
- package/nitrogen/generated/shared/c++/RNLocation.hpp +41 -2
- package/nitrogen/generated/shared/c++/RNLocationAndroid.hpp +104 -0
- package/nitrogen/generated/shared/c++/RNLocationConfig.hpp +8 -0
- package/nitrogen/generated/shared/c++/RNLocationIOS.hpp +99 -0
- package/nitrogen/generated/shared/c++/RNLocationPermissionResult.hpp +8 -0
- package/nitrogen/generated/shared/c++/RNMapPadding.hpp +8 -0
- package/nitrogen/generated/shared/c++/RNMapUiSettings.hpp +8 -0
- package/nitrogen/generated/shared/c++/RNMapZoomConfig.hpp +8 -0
- package/nitrogen/generated/shared/c++/RNMarker.hpp +17 -1
- package/nitrogen/generated/shared/c++/RNMarkerSvg.hpp +8 -0
- package/nitrogen/generated/shared/c++/RNPolygon.hpp +21 -2
- package/nitrogen/generated/shared/c++/RNPolygonHole.hpp +77 -0
- package/nitrogen/generated/shared/c++/RNPolyline.hpp +13 -1
- package/nitrogen/generated/shared/c++/RNPosition.hpp +8 -0
- package/nitrogen/generated/shared/c++/RNRegion.hpp +8 -0
- package/nitrogen/generated/shared/c++/RNSize.hpp +8 -0
- package/nitrogen/generated/shared/c++/RNSnapshotOptions.hpp +8 -0
- package/package.json +9 -16
- package/src/GoogleMapsPlus.tsx +20 -0
- package/src/index.tsx +6 -14
- package/src/types.ts +36 -0
- package/lib/module/package.json +0 -1
- package/lib/typescript/package.json +0 -1
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
{
|
|
2
|
+
"uiViewClassName": "RNGoogleMapsPlusView",
|
|
3
|
+
"supportsRawText": false,
|
|
4
|
+
"bubblingEventTypes": {},
|
|
5
|
+
"directEventTypes": {},
|
|
6
|
+
"validAttributes": {
|
|
7
|
+
"initialProps": true,
|
|
8
|
+
"uiSettings": true,
|
|
9
|
+
"myLocationEnabled": true,
|
|
10
|
+
"buildingEnabled": true,
|
|
11
|
+
"trafficEnabled": true,
|
|
12
|
+
"indoorEnabled": true,
|
|
13
|
+
"customMapStyle": true,
|
|
14
|
+
"userInterfaceStyle": true,
|
|
15
|
+
"mapZoomConfig": true,
|
|
16
|
+
"mapPadding": true,
|
|
17
|
+
"mapType": true,
|
|
18
|
+
"markers": true,
|
|
19
|
+
"polygons": true,
|
|
20
|
+
"polylines": true,
|
|
21
|
+
"circles": true,
|
|
22
|
+
"heatmaps": true,
|
|
23
|
+
"kmlLayers": true,
|
|
24
|
+
"locationConfig": true,
|
|
25
|
+
"onMapError": true,
|
|
26
|
+
"onMapReady": true,
|
|
27
|
+
"onLocationUpdate": true,
|
|
28
|
+
"onLocationError": true,
|
|
29
|
+
"onMapPress": true,
|
|
30
|
+
"onMarkerPress": true,
|
|
31
|
+
"onPolylinePress": true,
|
|
32
|
+
"onPolygonPress": true,
|
|
33
|
+
"onCirclePress": true,
|
|
34
|
+
"onMarkerDragStart": true,
|
|
35
|
+
"onMarkerDrag": true,
|
|
36
|
+
"onMarkerDragEnd": true,
|
|
37
|
+
"onIndoorBuildingFocused": true,
|
|
38
|
+
"onIndoorLevelActivated": true,
|
|
39
|
+
"onCameraChangeStart": true,
|
|
40
|
+
"onCameraChange": true,
|
|
41
|
+
"onCameraChangeComplete": true,
|
|
42
|
+
"hybridRef": true
|
|
43
|
+
}
|
|
44
|
+
}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import type { RNGoogleMapsPlusViewMethods, RNGoogleMapsPlusViewProps } from './RNGoogleMapsPlusView.nitro.js';
|
|
2
|
+
import type { RNGoogleMapsPlusModule } from './RNGoogleMapsPlusModule.nitro.js';
|
|
3
|
+
export declare const GoogleMapsView: import("react-native-nitro-modules").ReactNativeView<RNGoogleMapsPlusViewProps, RNGoogleMapsPlusViewMethods>;
|
|
4
|
+
export declare const GoogleMapsModule: RNGoogleMapsPlusModule;
|
|
5
|
+
//# sourceMappingURL=GoogleMapsPlus.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"GoogleMapsPlus.d.ts","sourceRoot":"","sources":["../../../src/GoogleMapsPlus.tsx"],"names":[],"mappings":"AAIA,OAAO,KAAK,EACV,2BAA2B,EAC3B,yBAAyB,EAC1B,MAAM,iCAAiC,CAAC;AAEzC,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,mCAAmC,CAAC;AAEhF,eAAO,MAAM,cAAc,8GAGgB,CAAC;AAE5C,eAAO,MAAM,gBAAgB,wBAG1B,CAAC"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
+
import { GoogleMapsView, GoogleMapsModule } from './GoogleMapsPlus';
|
|
1
2
|
import type { RNGoogleMapsPlusViewMethods, RNGoogleMapsPlusViewProps } from './RNGoogleMapsPlusView.nitro';
|
|
2
3
|
import type { RNGoogleMapsPlusModule } from './RNGoogleMapsPlusModule.nitro';
|
|
3
4
|
export * from './types';
|
|
4
|
-
export type { RNGoogleMapsPlusViewMethods, RNGoogleMapsPlusViewProps };
|
|
5
|
-
export
|
|
6
|
-
export declare const GoogleMapsModule: RNGoogleMapsPlusModule;
|
|
5
|
+
export type { RNGoogleMapsPlusViewMethods, RNGoogleMapsPlusViewProps, RNGoogleMapsPlusModule, };
|
|
6
|
+
export { GoogleMapsView, GoogleMapsModule };
|
|
7
7
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/index.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/index.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,gBAAgB,EAAE,MAAM,kBAAkB,CAAC;AACpE,OAAO,KAAK,EACV,2BAA2B,EAC3B,yBAAyB,EAC1B,MAAM,8BAA8B,CAAC;AACtC,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,gCAAgC,CAAC;AAE7E,cAAc,SAAS,CAAC;AAExB,YAAY,EACV,2BAA2B,EAC3B,yBAAyB,EACzB,sBAAsB,GACvB,CAAC;AAEF,OAAO,EAAE,cAAc,EAAE,gBAAgB,EAAE,CAAC"}
|
|
@@ -96,6 +96,8 @@ export type RNMarker = {
|
|
|
96
96
|
opacity?: number;
|
|
97
97
|
flat?: boolean;
|
|
98
98
|
draggable?: boolean;
|
|
99
|
+
rotation?: number;
|
|
100
|
+
infoWindowAnchor?: RNPosition;
|
|
99
101
|
iconSvg?: RNMarkerSvg;
|
|
100
102
|
};
|
|
101
103
|
export type RNMarkerSvg = {
|
|
@@ -111,6 +113,11 @@ export type RNPolygon = {
|
|
|
111
113
|
fillColor?: string;
|
|
112
114
|
strokeColor?: string;
|
|
113
115
|
strokeWidth?: number;
|
|
116
|
+
holes?: RNPolygonHole[];
|
|
117
|
+
geodesic?: boolean;
|
|
118
|
+
};
|
|
119
|
+
export type RNPolygonHole = {
|
|
120
|
+
coordinates: RNLatLng[];
|
|
114
121
|
};
|
|
115
122
|
export type RNPolyline = {
|
|
116
123
|
id: string;
|
|
@@ -119,6 +126,7 @@ export type RNPolyline = {
|
|
|
119
126
|
coordinates: RNLatLng[];
|
|
120
127
|
lineCap?: RNLineCapType;
|
|
121
128
|
lineJoin?: RNLineJoinType;
|
|
129
|
+
geodesic?: boolean;
|
|
122
130
|
color?: string;
|
|
123
131
|
width?: number;
|
|
124
132
|
};
|
|
@@ -207,7 +215,32 @@ export declare enum RNIOSPermissionResult {
|
|
|
207
215
|
}
|
|
208
216
|
export type RNLocation = {
|
|
209
217
|
center: RNLatLng;
|
|
218
|
+
altitude: number;
|
|
219
|
+
accuracy: number;
|
|
210
220
|
bearing: number;
|
|
221
|
+
speed: number;
|
|
222
|
+
time: number;
|
|
223
|
+
android?: RNLocationAndroid;
|
|
224
|
+
ios?: RNLocationIOS;
|
|
225
|
+
};
|
|
226
|
+
export type RNLocationAndroid = {
|
|
227
|
+
provider?: string | null;
|
|
228
|
+
elapsedRealtimeNanos?: number;
|
|
229
|
+
bearingAccuracyDegrees?: number;
|
|
230
|
+
speedAccuracyMetersPerSecond?: number;
|
|
231
|
+
verticalAccuracyMeters?: number;
|
|
232
|
+
mslAltitudeMeters?: number;
|
|
233
|
+
mslAltitudeAccuracyMeters?: number;
|
|
234
|
+
isMock?: boolean;
|
|
235
|
+
};
|
|
236
|
+
export type RNLocationIOS = {
|
|
237
|
+
horizontalAccuracy?: number;
|
|
238
|
+
verticalAccuracy?: number;
|
|
239
|
+
speedAccuracy?: number;
|
|
240
|
+
courseAccuracy?: number;
|
|
241
|
+
floor?: number | null;
|
|
242
|
+
isFromMockProvider?: boolean;
|
|
243
|
+
timestamp?: number;
|
|
211
244
|
};
|
|
212
245
|
export declare enum RNLocationErrorCode {
|
|
213
246
|
PERMISSION_DENIED = 1,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,2BAA2B,EAA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B,CAAC,EAAE,MAAM,CAAC;IACnC,MAAM,CAAC,EAAE,OAAO,CAAC;CAClB,CAAC;AACF,MAAM,MAAM,aAAa,GAAG;IAC1B,kBAAkB,CAAC,EAAE,MAAM,CAAC;IAC5B,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAC1B,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,KAAK,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACtB,kBAAkB,CAAC,EAAE,OAAO,CAAC;IAC7B,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB,CAAC;AAEF,oBAAY,mBAAmB;IAC7B,iBAAiB,IAAI;IACrB,oBAAoB,IAAI;IACxB,OAAO,IAAI;IACX,0BAA0B,IAAI;IAC9B,sBAAsB,IAAI;IAC1B,cAAc,KAAK;CACpB;AAED,oBAAY,cAAc;IACxB,qBAAqB,IAAI;IACzB,qBAAqB,IAAI;IACzB,sBAAsB,IAAI;IAC1B,sBAAsB,IAAI;IAC1B,6BAA6B,IAAI;IACjC,qBAAqB,IAAI;IACzB,OAAO,IAAI;CACZ"}
|
|
@@ -15,6 +15,12 @@
|
|
|
15
15
|
#include "JRNLocation.hpp"
|
|
16
16
|
#include "RNLatLng.hpp"
|
|
17
17
|
#include "JRNLatLng.hpp"
|
|
18
|
+
#include "RNLocationAndroid.hpp"
|
|
19
|
+
#include <optional>
|
|
20
|
+
#include "JRNLocationAndroid.hpp"
|
|
21
|
+
#include <string>
|
|
22
|
+
#include "RNLocationIOS.hpp"
|
|
23
|
+
#include "JRNLocationIOS.hpp"
|
|
18
24
|
|
|
19
25
|
namespace margelo::nitro::rngooglemapsplus {
|
|
20
26
|
|
|
@@ -31,6 +31,8 @@ namespace margelo::nitro::rngooglemapsplus { struct RNPosition; }
|
|
|
31
31
|
namespace margelo::nitro::rngooglemapsplus { struct RNMarkerSvg; }
|
|
32
32
|
// Forward declaration of `RNPolygon` to properly resolve imports.
|
|
33
33
|
namespace margelo::nitro::rngooglemapsplus { struct RNPolygon; }
|
|
34
|
+
// Forward declaration of `RNPolygonHole` to properly resolve imports.
|
|
35
|
+
namespace margelo::nitro::rngooglemapsplus { struct RNPolygonHole; }
|
|
34
36
|
// Forward declaration of `RNPolyline` to properly resolve imports.
|
|
35
37
|
namespace margelo::nitro::rngooglemapsplus { struct RNPolyline; }
|
|
36
38
|
// Forward declaration of `RNLineCapType` to properly resolve imports.
|
|
@@ -61,6 +63,10 @@ namespace margelo::nitro::rngooglemapsplus { enum class RNIOSLocationAccuracy; }
|
|
|
61
63
|
namespace margelo::nitro::rngooglemapsplus { enum class RNMapErrorCode; }
|
|
62
64
|
// Forward declaration of `RNLocation` to properly resolve imports.
|
|
63
65
|
namespace margelo::nitro::rngooglemapsplus { struct RNLocation; }
|
|
66
|
+
// Forward declaration of `RNLocationAndroid` to properly resolve imports.
|
|
67
|
+
namespace margelo::nitro::rngooglemapsplus { struct RNLocationAndroid; }
|
|
68
|
+
// Forward declaration of `RNLocationIOS` to properly resolve imports.
|
|
69
|
+
namespace margelo::nitro::rngooglemapsplus { struct RNLocationIOS; }
|
|
64
70
|
// Forward declaration of `RNLocationErrorCode` to properly resolve imports.
|
|
65
71
|
namespace margelo::nitro::rngooglemapsplus { enum class RNLocationErrorCode; }
|
|
66
72
|
// Forward declaration of `RNIndoorBuilding` to properly resolve imports.
|
|
@@ -113,6 +119,8 @@ namespace margelo::nitro::rngooglemapsplus { enum class RNSnapshotResultType; }
|
|
|
113
119
|
#include "JRNMarkerSvg.hpp"
|
|
114
120
|
#include "RNPolygon.hpp"
|
|
115
121
|
#include "JRNPolygon.hpp"
|
|
122
|
+
#include "RNPolygonHole.hpp"
|
|
123
|
+
#include "JRNPolygonHole.hpp"
|
|
116
124
|
#include "RNPolyline.hpp"
|
|
117
125
|
#include "JRNPolyline.hpp"
|
|
118
126
|
#include "RNLineCapType.hpp"
|
|
@@ -147,6 +155,10 @@ namespace margelo::nitro::rngooglemapsplus { enum class RNSnapshotResultType; }
|
|
|
147
155
|
#include "RNLocation.hpp"
|
|
148
156
|
#include "JFunc_void_RNLocation.hpp"
|
|
149
157
|
#include "JRNLocation.hpp"
|
|
158
|
+
#include "RNLocationAndroid.hpp"
|
|
159
|
+
#include "JRNLocationAndroid.hpp"
|
|
160
|
+
#include "RNLocationIOS.hpp"
|
|
161
|
+
#include "JRNLocationIOS.hpp"
|
|
150
162
|
#include "RNLocationErrorCode.hpp"
|
|
151
163
|
#include "JFunc_void_RNLocationErrorCode.hpp"
|
|
152
164
|
#include "JRNLocationErrorCode.hpp"
|
|
@@ -11,7 +11,13 @@
|
|
|
11
11
|
#include "RNLocation.hpp"
|
|
12
12
|
|
|
13
13
|
#include "JRNLatLng.hpp"
|
|
14
|
+
#include "JRNLocationAndroid.hpp"
|
|
15
|
+
#include "JRNLocationIOS.hpp"
|
|
14
16
|
#include "RNLatLng.hpp"
|
|
17
|
+
#include "RNLocationAndroid.hpp"
|
|
18
|
+
#include "RNLocationIOS.hpp"
|
|
19
|
+
#include <optional>
|
|
20
|
+
#include <string>
|
|
15
21
|
|
|
16
22
|
namespace margelo::nitro::rngooglemapsplus {
|
|
17
23
|
|
|
@@ -34,11 +40,29 @@ namespace margelo::nitro::rngooglemapsplus {
|
|
|
34
40
|
static const auto clazz = javaClassStatic();
|
|
35
41
|
static const auto fieldCenter = clazz->getField<JRNLatLng>("center");
|
|
36
42
|
jni::local_ref<JRNLatLng> center = this->getFieldValue(fieldCenter);
|
|
43
|
+
static const auto fieldAltitude = clazz->getField<double>("altitude");
|
|
44
|
+
double altitude = this->getFieldValue(fieldAltitude);
|
|
45
|
+
static const auto fieldAccuracy = clazz->getField<double>("accuracy");
|
|
46
|
+
double accuracy = this->getFieldValue(fieldAccuracy);
|
|
37
47
|
static const auto fieldBearing = clazz->getField<double>("bearing");
|
|
38
48
|
double bearing = this->getFieldValue(fieldBearing);
|
|
49
|
+
static const auto fieldSpeed = clazz->getField<double>("speed");
|
|
50
|
+
double speed = this->getFieldValue(fieldSpeed);
|
|
51
|
+
static const auto fieldTime = clazz->getField<double>("time");
|
|
52
|
+
double time = this->getFieldValue(fieldTime);
|
|
53
|
+
static const auto fieldAndroid = clazz->getField<JRNLocationAndroid>("android");
|
|
54
|
+
jni::local_ref<JRNLocationAndroid> android = this->getFieldValue(fieldAndroid);
|
|
55
|
+
static const auto fieldIos = clazz->getField<JRNLocationIOS>("ios");
|
|
56
|
+
jni::local_ref<JRNLocationIOS> ios = this->getFieldValue(fieldIos);
|
|
39
57
|
return RNLocation(
|
|
40
58
|
center->toCpp(),
|
|
41
|
-
|
|
59
|
+
altitude,
|
|
60
|
+
accuracy,
|
|
61
|
+
bearing,
|
|
62
|
+
speed,
|
|
63
|
+
time,
|
|
64
|
+
android != nullptr ? std::make_optional(android->toCpp()) : std::nullopt,
|
|
65
|
+
ios != nullptr ? std::make_optional(ios->toCpp()) : std::nullopt
|
|
42
66
|
);
|
|
43
67
|
}
|
|
44
68
|
|
|
@@ -50,7 +74,13 @@ namespace margelo::nitro::rngooglemapsplus {
|
|
|
50
74
|
static jni::local_ref<JRNLocation::javaobject> fromCpp(const RNLocation& value) {
|
|
51
75
|
return newInstance(
|
|
52
76
|
JRNLatLng::fromCpp(value.center),
|
|
53
|
-
value.
|
|
77
|
+
value.altitude,
|
|
78
|
+
value.accuracy,
|
|
79
|
+
value.bearing,
|
|
80
|
+
value.speed,
|
|
81
|
+
value.time,
|
|
82
|
+
value.android.has_value() ? JRNLocationAndroid::fromCpp(value.android.value()) : nullptr,
|
|
83
|
+
value.ios.has_value() ? JRNLocationIOS::fromCpp(value.ios.value()) : nullptr
|
|
54
84
|
);
|
|
55
85
|
}
|
|
56
86
|
};
|
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
///
|
|
2
|
+
/// JRNLocationAndroid.hpp
|
|
3
|
+
/// This file was generated by nitrogen. DO NOT MODIFY THIS FILE.
|
|
4
|
+
/// https://github.com/mrousavy/nitro
|
|
5
|
+
/// Copyright © 2025 Marc Rousavy @ Margelo
|
|
6
|
+
///
|
|
7
|
+
|
|
8
|
+
#pragma once
|
|
9
|
+
|
|
10
|
+
#include <fbjni/fbjni.h>
|
|
11
|
+
#include "RNLocationAndroid.hpp"
|
|
12
|
+
|
|
13
|
+
#include <optional>
|
|
14
|
+
#include <string>
|
|
15
|
+
|
|
16
|
+
namespace margelo::nitro::rngooglemapsplus {
|
|
17
|
+
|
|
18
|
+
using namespace facebook;
|
|
19
|
+
|
|
20
|
+
/**
|
|
21
|
+
* The C++ JNI bridge between the C++ struct "RNLocationAndroid" and the the Kotlin data class "RNLocationAndroid".
|
|
22
|
+
*/
|
|
23
|
+
struct JRNLocationAndroid final: public jni::JavaClass<JRNLocationAndroid> {
|
|
24
|
+
public:
|
|
25
|
+
static auto constexpr kJavaDescriptor = "Lcom/rngooglemapsplus/RNLocationAndroid;";
|
|
26
|
+
|
|
27
|
+
public:
|
|
28
|
+
/**
|
|
29
|
+
* Convert this Java/Kotlin-based struct to the C++ struct RNLocationAndroid by copying all values to C++.
|
|
30
|
+
*/
|
|
31
|
+
[[maybe_unused]]
|
|
32
|
+
[[nodiscard]]
|
|
33
|
+
RNLocationAndroid toCpp() const {
|
|
34
|
+
static const auto clazz = javaClassStatic();
|
|
35
|
+
static const auto fieldProvider = clazz->getField<jni::JString>("provider");
|
|
36
|
+
jni::local_ref<jni::JString> provider = this->getFieldValue(fieldProvider);
|
|
37
|
+
static const auto fieldElapsedRealtimeNanos = clazz->getField<jni::JDouble>("elapsedRealtimeNanos");
|
|
38
|
+
jni::local_ref<jni::JDouble> elapsedRealtimeNanos = this->getFieldValue(fieldElapsedRealtimeNanos);
|
|
39
|
+
static const auto fieldBearingAccuracyDegrees = clazz->getField<jni::JDouble>("bearingAccuracyDegrees");
|
|
40
|
+
jni::local_ref<jni::JDouble> bearingAccuracyDegrees = this->getFieldValue(fieldBearingAccuracyDegrees);
|
|
41
|
+
static const auto fieldSpeedAccuracyMetersPerSecond = clazz->getField<jni::JDouble>("speedAccuracyMetersPerSecond");
|
|
42
|
+
jni::local_ref<jni::JDouble> speedAccuracyMetersPerSecond = this->getFieldValue(fieldSpeedAccuracyMetersPerSecond);
|
|
43
|
+
static const auto fieldVerticalAccuracyMeters = clazz->getField<jni::JDouble>("verticalAccuracyMeters");
|
|
44
|
+
jni::local_ref<jni::JDouble> verticalAccuracyMeters = this->getFieldValue(fieldVerticalAccuracyMeters);
|
|
45
|
+
static const auto fieldMslAltitudeMeters = clazz->getField<jni::JDouble>("mslAltitudeMeters");
|
|
46
|
+
jni::local_ref<jni::JDouble> mslAltitudeMeters = this->getFieldValue(fieldMslAltitudeMeters);
|
|
47
|
+
static const auto fieldMslAltitudeAccuracyMeters = clazz->getField<jni::JDouble>("mslAltitudeAccuracyMeters");
|
|
48
|
+
jni::local_ref<jni::JDouble> mslAltitudeAccuracyMeters = this->getFieldValue(fieldMslAltitudeAccuracyMeters);
|
|
49
|
+
static const auto fieldIsMock = clazz->getField<jni::JBoolean>("isMock");
|
|
50
|
+
jni::local_ref<jni::JBoolean> isMock = this->getFieldValue(fieldIsMock);
|
|
51
|
+
return RNLocationAndroid(
|
|
52
|
+
provider != nullptr ? std::make_optional(provider->toStdString()) : std::nullopt,
|
|
53
|
+
elapsedRealtimeNanos != nullptr ? std::make_optional(elapsedRealtimeNanos->value()) : std::nullopt,
|
|
54
|
+
bearingAccuracyDegrees != nullptr ? std::make_optional(bearingAccuracyDegrees->value()) : std::nullopt,
|
|
55
|
+
speedAccuracyMetersPerSecond != nullptr ? std::make_optional(speedAccuracyMetersPerSecond->value()) : std::nullopt,
|
|
56
|
+
verticalAccuracyMeters != nullptr ? std::make_optional(verticalAccuracyMeters->value()) : std::nullopt,
|
|
57
|
+
mslAltitudeMeters != nullptr ? std::make_optional(mslAltitudeMeters->value()) : std::nullopt,
|
|
58
|
+
mslAltitudeAccuracyMeters != nullptr ? std::make_optional(mslAltitudeAccuracyMeters->value()) : std::nullopt,
|
|
59
|
+
isMock != nullptr ? std::make_optional(static_cast<bool>(isMock->value())) : std::nullopt
|
|
60
|
+
);
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
public:
|
|
64
|
+
/**
|
|
65
|
+
* Create a Java/Kotlin-based struct by copying all values from the given C++ struct to Java.
|
|
66
|
+
*/
|
|
67
|
+
[[maybe_unused]]
|
|
68
|
+
static jni::local_ref<JRNLocationAndroid::javaobject> fromCpp(const RNLocationAndroid& value) {
|
|
69
|
+
return newInstance(
|
|
70
|
+
value.provider.has_value() ? jni::make_jstring(value.provider.value()) : nullptr,
|
|
71
|
+
value.elapsedRealtimeNanos.has_value() ? jni::JDouble::valueOf(value.elapsedRealtimeNanos.value()) : nullptr,
|
|
72
|
+
value.bearingAccuracyDegrees.has_value() ? jni::JDouble::valueOf(value.bearingAccuracyDegrees.value()) : nullptr,
|
|
73
|
+
value.speedAccuracyMetersPerSecond.has_value() ? jni::JDouble::valueOf(value.speedAccuracyMetersPerSecond.value()) : nullptr,
|
|
74
|
+
value.verticalAccuracyMeters.has_value() ? jni::JDouble::valueOf(value.verticalAccuracyMeters.value()) : nullptr,
|
|
75
|
+
value.mslAltitudeMeters.has_value() ? jni::JDouble::valueOf(value.mslAltitudeMeters.value()) : nullptr,
|
|
76
|
+
value.mslAltitudeAccuracyMeters.has_value() ? jni::JDouble::valueOf(value.mslAltitudeAccuracyMeters.value()) : nullptr,
|
|
77
|
+
value.isMock.has_value() ? jni::JBoolean::valueOf(value.isMock.value()) : nullptr
|
|
78
|
+
);
|
|
79
|
+
}
|
|
80
|
+
};
|
|
81
|
+
|
|
82
|
+
} // namespace margelo::nitro::rngooglemapsplus
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
///
|
|
2
|
+
/// JRNLocationIOS.hpp
|
|
3
|
+
/// This file was generated by nitrogen. DO NOT MODIFY THIS FILE.
|
|
4
|
+
/// https://github.com/mrousavy/nitro
|
|
5
|
+
/// Copyright © 2025 Marc Rousavy @ Margelo
|
|
6
|
+
///
|
|
7
|
+
|
|
8
|
+
#pragma once
|
|
9
|
+
|
|
10
|
+
#include <fbjni/fbjni.h>
|
|
11
|
+
#include "RNLocationIOS.hpp"
|
|
12
|
+
|
|
13
|
+
#include <optional>
|
|
14
|
+
|
|
15
|
+
namespace margelo::nitro::rngooglemapsplus {
|
|
16
|
+
|
|
17
|
+
using namespace facebook;
|
|
18
|
+
|
|
19
|
+
/**
|
|
20
|
+
* The C++ JNI bridge between the C++ struct "RNLocationIOS" and the the Kotlin data class "RNLocationIOS".
|
|
21
|
+
*/
|
|
22
|
+
struct JRNLocationIOS final: public jni::JavaClass<JRNLocationIOS> {
|
|
23
|
+
public:
|
|
24
|
+
static auto constexpr kJavaDescriptor = "Lcom/rngooglemapsplus/RNLocationIOS;";
|
|
25
|
+
|
|
26
|
+
public:
|
|
27
|
+
/**
|
|
28
|
+
* Convert this Java/Kotlin-based struct to the C++ struct RNLocationIOS by copying all values to C++.
|
|
29
|
+
*/
|
|
30
|
+
[[maybe_unused]]
|
|
31
|
+
[[nodiscard]]
|
|
32
|
+
RNLocationIOS toCpp() const {
|
|
33
|
+
static const auto clazz = javaClassStatic();
|
|
34
|
+
static const auto fieldHorizontalAccuracy = clazz->getField<jni::JDouble>("horizontalAccuracy");
|
|
35
|
+
jni::local_ref<jni::JDouble> horizontalAccuracy = this->getFieldValue(fieldHorizontalAccuracy);
|
|
36
|
+
static const auto fieldVerticalAccuracy = clazz->getField<jni::JDouble>("verticalAccuracy");
|
|
37
|
+
jni::local_ref<jni::JDouble> verticalAccuracy = this->getFieldValue(fieldVerticalAccuracy);
|
|
38
|
+
static const auto fieldSpeedAccuracy = clazz->getField<jni::JDouble>("speedAccuracy");
|
|
39
|
+
jni::local_ref<jni::JDouble> speedAccuracy = this->getFieldValue(fieldSpeedAccuracy);
|
|
40
|
+
static const auto fieldCourseAccuracy = clazz->getField<jni::JDouble>("courseAccuracy");
|
|
41
|
+
jni::local_ref<jni::JDouble> courseAccuracy = this->getFieldValue(fieldCourseAccuracy);
|
|
42
|
+
static const auto fieldFloor = clazz->getField<jni::JDouble>("floor");
|
|
43
|
+
jni::local_ref<jni::JDouble> floor = this->getFieldValue(fieldFloor);
|
|
44
|
+
static const auto fieldIsFromMockProvider = clazz->getField<jni::JBoolean>("isFromMockProvider");
|
|
45
|
+
jni::local_ref<jni::JBoolean> isFromMockProvider = this->getFieldValue(fieldIsFromMockProvider);
|
|
46
|
+
static const auto fieldTimestamp = clazz->getField<jni::JDouble>("timestamp");
|
|
47
|
+
jni::local_ref<jni::JDouble> timestamp = this->getFieldValue(fieldTimestamp);
|
|
48
|
+
return RNLocationIOS(
|
|
49
|
+
horizontalAccuracy != nullptr ? std::make_optional(horizontalAccuracy->value()) : std::nullopt,
|
|
50
|
+
verticalAccuracy != nullptr ? std::make_optional(verticalAccuracy->value()) : std::nullopt,
|
|
51
|
+
speedAccuracy != nullptr ? std::make_optional(speedAccuracy->value()) : std::nullopt,
|
|
52
|
+
courseAccuracy != nullptr ? std::make_optional(courseAccuracy->value()) : std::nullopt,
|
|
53
|
+
floor != nullptr ? std::make_optional(floor->value()) : std::nullopt,
|
|
54
|
+
isFromMockProvider != nullptr ? std::make_optional(static_cast<bool>(isFromMockProvider->value())) : std::nullopt,
|
|
55
|
+
timestamp != nullptr ? std::make_optional(timestamp->value()) : std::nullopt
|
|
56
|
+
);
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
public:
|
|
60
|
+
/**
|
|
61
|
+
* Create a Java/Kotlin-based struct by copying all values from the given C++ struct to Java.
|
|
62
|
+
*/
|
|
63
|
+
[[maybe_unused]]
|
|
64
|
+
static jni::local_ref<JRNLocationIOS::javaobject> fromCpp(const RNLocationIOS& value) {
|
|
65
|
+
return newInstance(
|
|
66
|
+
value.horizontalAccuracy.has_value() ? jni::JDouble::valueOf(value.horizontalAccuracy.value()) : nullptr,
|
|
67
|
+
value.verticalAccuracy.has_value() ? jni::JDouble::valueOf(value.verticalAccuracy.value()) : nullptr,
|
|
68
|
+
value.speedAccuracy.has_value() ? jni::JDouble::valueOf(value.speedAccuracy.value()) : nullptr,
|
|
69
|
+
value.courseAccuracy.has_value() ? jni::JDouble::valueOf(value.courseAccuracy.value()) : nullptr,
|
|
70
|
+
value.floor.has_value() ? jni::JDouble::valueOf(value.floor.value()) : nullptr,
|
|
71
|
+
value.isFromMockProvider.has_value() ? jni::JBoolean::valueOf(value.isFromMockProvider.value()) : nullptr,
|
|
72
|
+
value.timestamp.has_value() ? jni::JDouble::valueOf(value.timestamp.value()) : nullptr
|
|
73
|
+
);
|
|
74
|
+
}
|
|
75
|
+
};
|
|
76
|
+
|
|
77
|
+
} // namespace margelo::nitro::rngooglemapsplus
|
|
@@ -58,6 +58,10 @@ namespace margelo::nitro::rngooglemapsplus {
|
|
|
58
58
|
jni::local_ref<jni::JBoolean> flat = this->getFieldValue(fieldFlat);
|
|
59
59
|
static const auto fieldDraggable = clazz->getField<jni::JBoolean>("draggable");
|
|
60
60
|
jni::local_ref<jni::JBoolean> draggable = this->getFieldValue(fieldDraggable);
|
|
61
|
+
static const auto fieldRotation = clazz->getField<jni::JDouble>("rotation");
|
|
62
|
+
jni::local_ref<jni::JDouble> rotation = this->getFieldValue(fieldRotation);
|
|
63
|
+
static const auto fieldInfoWindowAnchor = clazz->getField<JRNPosition>("infoWindowAnchor");
|
|
64
|
+
jni::local_ref<JRNPosition> infoWindowAnchor = this->getFieldValue(fieldInfoWindowAnchor);
|
|
61
65
|
static const auto fieldIconSvg = clazz->getField<JRNMarkerSvg>("iconSvg");
|
|
62
66
|
jni::local_ref<JRNMarkerSvg> iconSvg = this->getFieldValue(fieldIconSvg);
|
|
63
67
|
return RNMarker(
|
|
@@ -71,6 +75,8 @@ namespace margelo::nitro::rngooglemapsplus {
|
|
|
71
75
|
opacity != nullptr ? std::make_optional(opacity->value()) : std::nullopt,
|
|
72
76
|
flat != nullptr ? std::make_optional(static_cast<bool>(flat->value())) : std::nullopt,
|
|
73
77
|
draggable != nullptr ? std::make_optional(static_cast<bool>(draggable->value())) : std::nullopt,
|
|
78
|
+
rotation != nullptr ? std::make_optional(rotation->value()) : std::nullopt,
|
|
79
|
+
infoWindowAnchor != nullptr ? std::make_optional(infoWindowAnchor->toCpp()) : std::nullopt,
|
|
74
80
|
iconSvg != nullptr ? std::make_optional(iconSvg->toCpp()) : std::nullopt
|
|
75
81
|
);
|
|
76
82
|
}
|
|
@@ -92,6 +98,8 @@ namespace margelo::nitro::rngooglemapsplus {
|
|
|
92
98
|
value.opacity.has_value() ? jni::JDouble::valueOf(value.opacity.value()) : nullptr,
|
|
93
99
|
value.flat.has_value() ? jni::JBoolean::valueOf(value.flat.value()) : nullptr,
|
|
94
100
|
value.draggable.has_value() ? jni::JBoolean::valueOf(value.draggable.value()) : nullptr,
|
|
101
|
+
value.rotation.has_value() ? jni::JDouble::valueOf(value.rotation.value()) : nullptr,
|
|
102
|
+
value.infoWindowAnchor.has_value() ? JRNPosition::fromCpp(value.infoWindowAnchor.value()) : nullptr,
|
|
95
103
|
value.iconSvg.has_value() ? JRNMarkerSvg::fromCpp(value.iconSvg.value()) : nullptr
|
|
96
104
|
);
|
|
97
105
|
}
|
|
@@ -11,7 +11,9 @@
|
|
|
11
11
|
#include "RNPolygon.hpp"
|
|
12
12
|
|
|
13
13
|
#include "JRNLatLng.hpp"
|
|
14
|
+
#include "JRNPolygonHole.hpp"
|
|
14
15
|
#include "RNLatLng.hpp"
|
|
16
|
+
#include "RNPolygonHole.hpp"
|
|
15
17
|
#include <optional>
|
|
16
18
|
#include <string>
|
|
17
19
|
#include <vector>
|
|
@@ -49,6 +51,10 @@ namespace margelo::nitro::rngooglemapsplus {
|
|
|
49
51
|
jni::local_ref<jni::JString> strokeColor = this->getFieldValue(fieldStrokeColor);
|
|
50
52
|
static const auto fieldStrokeWidth = clazz->getField<jni::JDouble>("strokeWidth");
|
|
51
53
|
jni::local_ref<jni::JDouble> strokeWidth = this->getFieldValue(fieldStrokeWidth);
|
|
54
|
+
static const auto fieldHoles = clazz->getField<jni::JArrayClass<JRNPolygonHole>>("holes");
|
|
55
|
+
jni::local_ref<jni::JArrayClass<JRNPolygonHole>> holes = this->getFieldValue(fieldHoles);
|
|
56
|
+
static const auto fieldGeodesic = clazz->getField<jni::JBoolean>("geodesic");
|
|
57
|
+
jni::local_ref<jni::JBoolean> geodesic = this->getFieldValue(fieldGeodesic);
|
|
52
58
|
return RNPolygon(
|
|
53
59
|
id->toStdString(),
|
|
54
60
|
zIndex != nullptr ? std::make_optional(zIndex->value()) : std::nullopt,
|
|
@@ -65,7 +71,18 @@ namespace margelo::nitro::rngooglemapsplus {
|
|
|
65
71
|
}(),
|
|
66
72
|
fillColor != nullptr ? std::make_optional(fillColor->toStdString()) : std::nullopt,
|
|
67
73
|
strokeColor != nullptr ? std::make_optional(strokeColor->toStdString()) : std::nullopt,
|
|
68
|
-
strokeWidth != nullptr ? std::make_optional(strokeWidth->value()) : std::nullopt
|
|
74
|
+
strokeWidth != nullptr ? std::make_optional(strokeWidth->value()) : std::nullopt,
|
|
75
|
+
holes != nullptr ? std::make_optional([&]() {
|
|
76
|
+
size_t __size = holes->size();
|
|
77
|
+
std::vector<RNPolygonHole> __vector;
|
|
78
|
+
__vector.reserve(__size);
|
|
79
|
+
for (size_t __i = 0; __i < __size; __i++) {
|
|
80
|
+
auto __element = holes->getElement(__i);
|
|
81
|
+
__vector.push_back(__element->toCpp());
|
|
82
|
+
}
|
|
83
|
+
return __vector;
|
|
84
|
+
}()) : std::nullopt,
|
|
85
|
+
geodesic != nullptr ? std::make_optional(static_cast<bool>(geodesic->value())) : std::nullopt
|
|
69
86
|
);
|
|
70
87
|
}
|
|
71
88
|
|
|
@@ -90,7 +107,17 @@ namespace margelo::nitro::rngooglemapsplus {
|
|
|
90
107
|
}(),
|
|
91
108
|
value.fillColor.has_value() ? jni::make_jstring(value.fillColor.value()) : nullptr,
|
|
92
109
|
value.strokeColor.has_value() ? jni::make_jstring(value.strokeColor.value()) : nullptr,
|
|
93
|
-
value.strokeWidth.has_value() ? jni::JDouble::valueOf(value.strokeWidth.value()) : nullptr
|
|
110
|
+
value.strokeWidth.has_value() ? jni::JDouble::valueOf(value.strokeWidth.value()) : nullptr,
|
|
111
|
+
value.holes.has_value() ? [&]() {
|
|
112
|
+
size_t __size = value.holes.value().size();
|
|
113
|
+
jni::local_ref<jni::JArrayClass<JRNPolygonHole>> __array = jni::JArrayClass<JRNPolygonHole>::newArray(__size);
|
|
114
|
+
for (size_t __i = 0; __i < __size; __i++) {
|
|
115
|
+
const auto& __element = value.holes.value()[__i];
|
|
116
|
+
__array->setElement(__i, *JRNPolygonHole::fromCpp(__element));
|
|
117
|
+
}
|
|
118
|
+
return __array;
|
|
119
|
+
}() : nullptr,
|
|
120
|
+
value.geodesic.has_value() ? jni::JBoolean::valueOf(value.geodesic.value()) : nullptr
|
|
94
121
|
);
|
|
95
122
|
}
|
|
96
123
|
};
|
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
///
|
|
2
|
+
/// JRNPolygonHole.hpp
|
|
3
|
+
/// This file was generated by nitrogen. DO NOT MODIFY THIS FILE.
|
|
4
|
+
/// https://github.com/mrousavy/nitro
|
|
5
|
+
/// Copyright © 2025 Marc Rousavy @ Margelo
|
|
6
|
+
///
|
|
7
|
+
|
|
8
|
+
#pragma once
|
|
9
|
+
|
|
10
|
+
#include <fbjni/fbjni.h>
|
|
11
|
+
#include "RNPolygonHole.hpp"
|
|
12
|
+
|
|
13
|
+
#include "JRNLatLng.hpp"
|
|
14
|
+
#include "RNLatLng.hpp"
|
|
15
|
+
#include <vector>
|
|
16
|
+
|
|
17
|
+
namespace margelo::nitro::rngooglemapsplus {
|
|
18
|
+
|
|
19
|
+
using namespace facebook;
|
|
20
|
+
|
|
21
|
+
/**
|
|
22
|
+
* The C++ JNI bridge between the C++ struct "RNPolygonHole" and the the Kotlin data class "RNPolygonHole".
|
|
23
|
+
*/
|
|
24
|
+
struct JRNPolygonHole final: public jni::JavaClass<JRNPolygonHole> {
|
|
25
|
+
public:
|
|
26
|
+
static auto constexpr kJavaDescriptor = "Lcom/rngooglemapsplus/RNPolygonHole;";
|
|
27
|
+
|
|
28
|
+
public:
|
|
29
|
+
/**
|
|
30
|
+
* Convert this Java/Kotlin-based struct to the C++ struct RNPolygonHole by copying all values to C++.
|
|
31
|
+
*/
|
|
32
|
+
[[maybe_unused]]
|
|
33
|
+
[[nodiscard]]
|
|
34
|
+
RNPolygonHole toCpp() const {
|
|
35
|
+
static const auto clazz = javaClassStatic();
|
|
36
|
+
static const auto fieldCoordinates = clazz->getField<jni::JArrayClass<JRNLatLng>>("coordinates");
|
|
37
|
+
jni::local_ref<jni::JArrayClass<JRNLatLng>> coordinates = this->getFieldValue(fieldCoordinates);
|
|
38
|
+
return RNPolygonHole(
|
|
39
|
+
[&]() {
|
|
40
|
+
size_t __size = coordinates->size();
|
|
41
|
+
std::vector<RNLatLng> __vector;
|
|
42
|
+
__vector.reserve(__size);
|
|
43
|
+
for (size_t __i = 0; __i < __size; __i++) {
|
|
44
|
+
auto __element = coordinates->getElement(__i);
|
|
45
|
+
__vector.push_back(__element->toCpp());
|
|
46
|
+
}
|
|
47
|
+
return __vector;
|
|
48
|
+
}()
|
|
49
|
+
);
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
public:
|
|
53
|
+
/**
|
|
54
|
+
* Create a Java/Kotlin-based struct by copying all values from the given C++ struct to Java.
|
|
55
|
+
*/
|
|
56
|
+
[[maybe_unused]]
|
|
57
|
+
static jni::local_ref<JRNPolygonHole::javaobject> fromCpp(const RNPolygonHole& value) {
|
|
58
|
+
return newInstance(
|
|
59
|
+
[&]() {
|
|
60
|
+
size_t __size = value.coordinates.size();
|
|
61
|
+
jni::local_ref<jni::JArrayClass<JRNLatLng>> __array = jni::JArrayClass<JRNLatLng>::newArray(__size);
|
|
62
|
+
for (size_t __i = 0; __i < __size; __i++) {
|
|
63
|
+
const auto& __element = value.coordinates[__i];
|
|
64
|
+
__array->setElement(__i, *JRNLatLng::fromCpp(__element));
|
|
65
|
+
}
|
|
66
|
+
return __array;
|
|
67
|
+
}()
|
|
68
|
+
);
|
|
69
|
+
}
|
|
70
|
+
};
|
|
71
|
+
|
|
72
|
+
} // namespace margelo::nitro::rngooglemapsplus
|
|
@@ -51,6 +51,8 @@ namespace margelo::nitro::rngooglemapsplus {
|
|
|
51
51
|
jni::local_ref<JRNLineCapType> lineCap = this->getFieldValue(fieldLineCap);
|
|
52
52
|
static const auto fieldLineJoin = clazz->getField<JRNLineJoinType>("lineJoin");
|
|
53
53
|
jni::local_ref<JRNLineJoinType> lineJoin = this->getFieldValue(fieldLineJoin);
|
|
54
|
+
static const auto fieldGeodesic = clazz->getField<jni::JBoolean>("geodesic");
|
|
55
|
+
jni::local_ref<jni::JBoolean> geodesic = this->getFieldValue(fieldGeodesic);
|
|
54
56
|
static const auto fieldColor = clazz->getField<jni::JString>("color");
|
|
55
57
|
jni::local_ref<jni::JString> color = this->getFieldValue(fieldColor);
|
|
56
58
|
static const auto fieldWidth = clazz->getField<jni::JDouble>("width");
|
|
@@ -71,6 +73,7 @@ namespace margelo::nitro::rngooglemapsplus {
|
|
|
71
73
|
}(),
|
|
72
74
|
lineCap != nullptr ? std::make_optional(lineCap->toCpp()) : std::nullopt,
|
|
73
75
|
lineJoin != nullptr ? std::make_optional(lineJoin->toCpp()) : std::nullopt,
|
|
76
|
+
geodesic != nullptr ? std::make_optional(static_cast<bool>(geodesic->value())) : std::nullopt,
|
|
74
77
|
color != nullptr ? std::make_optional(color->toStdString()) : std::nullopt,
|
|
75
78
|
width != nullptr ? std::make_optional(width->value()) : std::nullopt
|
|
76
79
|
);
|
|
@@ -97,6 +100,7 @@ namespace margelo::nitro::rngooglemapsplus {
|
|
|
97
100
|
}(),
|
|
98
101
|
value.lineCap.has_value() ? JRNLineCapType::fromCpp(value.lineCap.value()) : nullptr,
|
|
99
102
|
value.lineJoin.has_value() ? JRNLineJoinType::fromCpp(value.lineJoin.value()) : nullptr,
|
|
103
|
+
value.geodesic.has_value() ? jni::JBoolean::valueOf(value.geodesic.value()) : nullptr,
|
|
100
104
|
value.color.has_value() ? jni::make_jstring(value.color.value()) : nullptr,
|
|
101
105
|
value.width.has_value() ? jni::JDouble::valueOf(value.width.value()) : nullptr
|
|
102
106
|
);
|
|
@@ -26,7 +26,25 @@ data class RNLocation
|
|
|
26
26
|
val center: RNLatLng,
|
|
27
27
|
@DoNotStrip
|
|
28
28
|
@Keep
|
|
29
|
-
val
|
|
29
|
+
val altitude: Double,
|
|
30
|
+
@DoNotStrip
|
|
31
|
+
@Keep
|
|
32
|
+
val accuracy: Double,
|
|
33
|
+
@DoNotStrip
|
|
34
|
+
@Keep
|
|
35
|
+
val bearing: Double,
|
|
36
|
+
@DoNotStrip
|
|
37
|
+
@Keep
|
|
38
|
+
val speed: Double,
|
|
39
|
+
@DoNotStrip
|
|
40
|
+
@Keep
|
|
41
|
+
val time: Double,
|
|
42
|
+
@DoNotStrip
|
|
43
|
+
@Keep
|
|
44
|
+
val android: RNLocationAndroid?,
|
|
45
|
+
@DoNotStrip
|
|
46
|
+
@Keep
|
|
47
|
+
val ios: RNLocationIOS?
|
|
30
48
|
) {
|
|
31
49
|
/* main constructor */
|
|
32
50
|
}
|