@kingstinct/react-native-healthkit 10.1.0 → 11.0.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/ios/CoreModule.swift +5 -15
- package/ios/CorrelationTypeModule.swift +7 -2
- package/ios/QuantityTypeModule.swift +62 -110
- package/ios/Serializers.swift +39 -66
- package/ios/WorkoutProxy.swift +38 -20
- package/ios/WorkoutsModule.swift +7 -18
- package/lib/commonjs/hooks/useMostRecentWorkout.js +2 -9
- package/lib/commonjs/hooks/useWorkoutById.js +1 -4
- package/lib/commonjs/utils/getMostRecentWorkout.js +1 -3
- package/lib/commonjs/utils/getWorkoutById.js +1 -3
- package/lib/module/hooks/useMostRecentWorkout.js +3 -10
- package/lib/module/hooks/useWorkoutById.js +1 -4
- package/lib/module/utils/getMostRecentWorkout.js +1 -3
- package/lib/module/utils/getWorkoutById.js +1 -3
- package/lib/typescript/healthkit.d.ts +1 -1
- package/lib/typescript/healthkit.ios.d.ts +1 -1
- package/lib/typescript/hooks/useMostRecentWorkout.d.ts +1 -4
- package/lib/typescript/specs/WorkoutProxy.nitro.d.ts +11 -0
- package/lib/typescript/types/Workouts.d.ts +0 -8
- package/lib/typescript/utils/getMostRecentWorkout.d.ts +1 -2
- package/lib/typescript/utils/getWorkoutById.d.ts +1 -2
- package/nitrogen/generated/ios/ReactNativeHealthkit-Swift-Cxx-Bridge.cpp +103 -87
- package/nitrogen/generated/ios/ReactNativeHealthkit-Swift-Cxx-Bridge.hpp +748 -493
- package/nitrogen/generated/ios/ReactNativeHealthkitAutolinking.mm +8 -8
- package/nitrogen/generated/ios/ReactNativeHealthkitAutolinking.swift +16 -16
- package/nitrogen/generated/ios/c++/HybridCategoryTypeModuleSpecSwift.hpp +6 -4
- package/nitrogen/generated/ios/c++/HybridCharacteristicTypeModuleSpecSwift.hpp +4 -2
- package/nitrogen/generated/ios/c++/HybridCoreModuleSpecSwift.hpp +7 -5
- package/nitrogen/generated/ios/c++/HybridCorrelationTypeModuleSpecSwift.hpp +6 -4
- package/nitrogen/generated/ios/c++/HybridHeartbeatSeriesModuleSpecSwift.hpp +7 -5
- package/nitrogen/generated/ios/c++/HybridQuantityTypeModuleSpecSwift.hpp +5 -3
- package/nitrogen/generated/ios/c++/HybridSourceProxySpecSwift.hpp +3 -1
- package/nitrogen/generated/ios/c++/HybridStateOfMindModuleSpecSwift.hpp +7 -5
- package/nitrogen/generated/ios/c++/HybridWorkoutProxySpecSwift.hpp +50 -22
- package/nitrogen/generated/ios/c++/HybridWorkoutsModuleSpecSwift.hpp +9 -7
- package/nitrogen/generated/ios/swift/CategorySample.swift +4 -2
- package/nitrogen/generated/ios/swift/CategorySampleForSaving.swift +2 -1
- package/nitrogen/generated/ios/swift/CorrelationObject.swift +2 -0
- package/nitrogen/generated/ios/swift/DeletedSample.swift +2 -1
- package/nitrogen/generated/ios/swift/Device.swift +16 -8
- package/nitrogen/generated/ios/swift/FilterForSamples.swift +2 -0
- package/nitrogen/generated/ios/swift/Func_void_AuthorizationRequestStatus.swift +1 -0
- package/nitrogen/generated/ios/swift/Func_void_BiologicalSex.swift +1 -0
- package/nitrogen/generated/ios/swift/Func_void_BloodType.swift +1 -0
- package/nitrogen/generated/ios/swift/Func_void_CategorySamplesWithAnchorResponse.swift +1 -0
- package/nitrogen/generated/ios/swift/Func_void_FitzpatrickSkinType.swift +1 -0
- package/nitrogen/generated/ios/swift/Func_void_HeartbeatSeriesSamplesWithAnchorResponse.swift +1 -0
- package/nitrogen/generated/ios/swift/Func_void_OnChangeCallbackArgs.swift +1 -0
- package/nitrogen/generated/ios/swift/Func_void_QuantitySamplesWithAnchorResponse.swift +1 -0
- package/nitrogen/generated/ios/swift/Func_void_QueryStatisticsResponse.swift +1 -0
- package/nitrogen/generated/ios/swift/Func_void_QueryWorkoutSamplesWithAnchorResponse.swift +1 -0
- package/nitrogen/generated/ios/swift/Func_void_WheelchairUse.swift +1 -0
- package/nitrogen/generated/ios/swift/Func_void_bool.swift +1 -0
- package/nitrogen/generated/ios/swift/Func_void_double.swift +1 -0
- package/nitrogen/generated/ios/swift/Func_void_std__exception_ptr.swift +1 -0
- package/nitrogen/generated/ios/swift/Func_void_std__optional_QueryStatisticsResponse_.swift +54 -0
- package/nitrogen/generated/ios/swift/Func_void_std__optional_WorkoutPlan_.swift +3 -1
- package/nitrogen/generated/ios/swift/Func_void_std__optional_std__chrono__system_clock__time_point_.swift +3 -1
- package/nitrogen/generated/ios/swift/{Func_void_std__shared_ptr_margelo__nitro__healthkit__HybridWorkoutProxySpec_.swift → Func_void_std__shared_ptr_HybridWorkoutProxySpec_.swift} +9 -8
- package/nitrogen/generated/ios/swift/Func_void_std__unordered_map_std__string__QueryStatisticsResponse_.swift +55 -0
- package/nitrogen/generated/ios/swift/Func_void_std__unordered_map_std__string__bool_.swift +2 -1
- package/nitrogen/generated/ios/swift/Func_void_std__vector_CategorySample_.swift +1 -0
- package/nitrogen/generated/ios/swift/Func_void_std__vector_CorrelationSample_.swift +1 -0
- package/nitrogen/generated/ios/swift/Func_void_std__vector_HeartbeatSeriesSample_.swift +1 -0
- package/nitrogen/generated/ios/swift/Func_void_std__vector_IdentifierWithUnit_.swift +1 -0
- package/nitrogen/generated/ios/swift/Func_void_std__vector_QuantitySample_.swift +1 -0
- package/nitrogen/generated/ios/swift/Func_void_std__vector_QueryStatisticsResponse_.swift +1 -0
- package/nitrogen/generated/ios/swift/Func_void_std__vector_StateOfMindSample_.swift +1 -0
- package/nitrogen/generated/ios/swift/Func_void_std__vector_WorkoutRoute_.swift +1 -0
- package/nitrogen/generated/ios/swift/{Func_void_std__vector_std__shared_ptr_margelo__nitro__healthkit__HybridSourceProxySpec__.swift → Func_void_std__vector_std__shared_ptr_HybridSourceProxySpec__.swift} +9 -8
- package/nitrogen/generated/ios/swift/{Func_void_std__vector_std__shared_ptr_margelo__nitro__healthkit__HybridWorkoutProxySpec__.swift → Func_void_std__vector_std__shared_ptr_HybridWorkoutProxySpec__.swift} +9 -8
- package/nitrogen/generated/ios/swift/HeartbeatSeriesSample.swift +6 -3
- package/nitrogen/generated/ios/swift/HybridCategoryTypeModuleSpec.swift +2 -1
- package/nitrogen/generated/ios/swift/HybridCategoryTypeModuleSpec_cxx.swift +17 -7
- package/nitrogen/generated/ios/swift/HybridCharacteristicTypeModuleSpec.swift +2 -1
- package/nitrogen/generated/ios/swift/HybridCharacteristicTypeModuleSpec_cxx.swift +15 -6
- package/nitrogen/generated/ios/swift/HybridCoreModuleSpec.swift +2 -1
- package/nitrogen/generated/ios/swift/HybridCoreModuleSpec_cxx.swift +24 -15
- package/nitrogen/generated/ios/swift/HybridCorrelationTypeModuleSpec.swift +2 -1
- package/nitrogen/generated/ios/swift/HybridCorrelationTypeModuleSpec_cxx.swift +15 -6
- package/nitrogen/generated/ios/swift/HybridHeartbeatSeriesModuleSpec.swift +2 -1
- package/nitrogen/generated/ios/swift/HybridHeartbeatSeriesModuleSpec_cxx.swift +17 -7
- package/nitrogen/generated/ios/swift/HybridQuantityTypeModuleSpec.swift +2 -1
- package/nitrogen/generated/ios/swift/HybridQuantityTypeModuleSpec_cxx.swift +21 -9
- package/nitrogen/generated/ios/swift/HybridSourceProxySpec.swift +2 -1
- package/nitrogen/generated/ios/swift/HybridSourceProxySpec_cxx.swift +17 -7
- package/nitrogen/generated/ios/swift/HybridStateOfMindModuleSpec.swift +2 -1
- package/nitrogen/generated/ios/swift/HybridStateOfMindModuleSpec_cxx.swift +19 -8
- package/nitrogen/generated/ios/swift/HybridWorkoutProxySpec.swift +8 -5
- package/nitrogen/generated/ios/swift/HybridWorkoutProxySpec_cxx.swift +108 -41
- package/nitrogen/generated/ios/swift/HybridWorkoutsModuleSpec.swift +2 -1
- package/nitrogen/generated/ios/swift/HybridWorkoutsModuleSpec_cxx.swift +31 -22
- package/nitrogen/generated/ios/swift/OnChangeCallbackArgs.swift +2 -1
- package/nitrogen/generated/ios/swift/PredicateForSamples.swift +2 -0
- package/nitrogen/generated/ios/swift/PredicateForWorkouts.swift +2 -0
- package/nitrogen/generated/ios/swift/PredicateFromWorkout.swift +3 -3
- package/nitrogen/generated/ios/swift/PredicateWithMetadataKey.swift +2 -1
- package/nitrogen/generated/ios/swift/PredicateWithStartAndEnd.swift +4 -2
- package/nitrogen/generated/ios/swift/QuantitySample.swift +4 -2
- package/nitrogen/generated/ios/swift/QuantitySampleForSaving.swift +2 -1
- package/nitrogen/generated/ios/swift/QueryOptionsWithAnchor.swift +4 -2
- package/nitrogen/generated/ios/swift/QueryOptionsWithAnchorAndUnit.swift +6 -3
- package/nitrogen/generated/ios/swift/QueryOptionsWithSortOrder.swift +2 -1
- package/nitrogen/generated/ios/swift/QueryOptionsWithSortOrderAndUnit.swift +4 -2
- package/nitrogen/generated/ios/swift/QueryStatisticsResponse.swift +18 -9
- package/nitrogen/generated/ios/swift/QueryWorkoutSamplesWithAnchorResponse.swift +7 -7
- package/nitrogen/generated/ios/swift/SampleForSaving.swift +2 -0
- package/nitrogen/generated/ios/swift/SourceRevision.swift +13 -9
- package/nitrogen/generated/ios/swift/StateOfMindSample.swift +6 -3
- package/nitrogen/generated/ios/swift/StatisticsQueryOptions.swift +4 -2
- package/nitrogen/generated/ios/swift/Variant_PredicateWithUUID_PredicateWithUUIDs_PredicateWithMetadataKey_PredicateWithStartAndEnd_PredicateFromWorkout_FilterForSamplesAnd_FilterForSamplesOr.swift +2 -0
- package/nitrogen/generated/ios/swift/Variant_PredicateWithUUID_PredicateWithUUIDs_PredicateWithMetadataKey_PredicateWithStartAndEnd_PredicateFromWorkout_WorkoutActivityTypePredicate_WorkoutDurationPredicate_PredicateForWorkoutsOr_PredicateForWorkoutsAnd.swift +2 -0
- package/nitrogen/generated/ios/swift/Variant_String_Double_Bool_Date.swift +2 -0
- package/nitrogen/generated/ios/swift/WorkoutQueryOptions.swift +4 -61
- package/nitrogen/generated/ios/swift/WorkoutQueryOptionsWithAnchor.swift +6 -62
- package/nitrogen/generated/ios/swift/WorkoutRoute.swift +2 -1
- package/nitrogen/generated/ios/swift/WorkoutSample.swift +12 -123
- package/nitrogen/generated/shared/c++/AuthorizationRequestStatus.hpp +9 -11
- package/nitrogen/generated/shared/c++/AuthorizationStatus.hpp +9 -11
- package/nitrogen/generated/shared/c++/BiologicalSex.hpp +9 -11
- package/nitrogen/generated/shared/c++/BloodType.hpp +9 -11
- package/nitrogen/generated/shared/c++/CategorySample.hpp +14 -16
- package/nitrogen/generated/shared/c++/CategorySampleForSaving.hpp +11 -13
- package/nitrogen/generated/shared/c++/CategorySamplesWithAnchorResponse.hpp +11 -13
- package/nitrogen/generated/shared/c++/CategoryTypeIdentifier.hpp +131 -133
- package/nitrogen/generated/shared/c++/ComparisonPredicateOperator.hpp +26 -13
- package/nitrogen/generated/shared/c++/CorrelationSample.hpp +12 -14
- package/nitrogen/generated/shared/c++/CorrelationTypeIdentifier.hpp +7 -9
- package/nitrogen/generated/shared/c++/DeletedSample.hpp +5 -7
- package/nitrogen/generated/shared/c++/Device.hpp +5 -7
- package/nitrogen/generated/shared/c++/FilterForSamplesAnd.hpp +9 -11
- package/nitrogen/generated/shared/c++/FilterForSamplesOr.hpp +9 -11
- package/nitrogen/generated/shared/c++/FitzpatrickSkinType.hpp +9 -11
- package/nitrogen/generated/shared/c++/Heartbeat.hpp +4 -6
- package/nitrogen/generated/shared/c++/HeartbeatSeriesSample.hpp +15 -17
- package/nitrogen/generated/shared/c++/HeartbeatSeriesSamplesWithAnchorResponse.hpp +11 -13
- package/nitrogen/generated/shared/c++/HybridCategoryTypeModuleSpec.hpp +2 -2
- package/nitrogen/generated/shared/c++/HybridCharacteristicTypeModuleSpec.hpp +1 -1
- package/nitrogen/generated/shared/c++/HybridCoreModuleSpec.hpp +4 -4
- package/nitrogen/generated/shared/c++/HybridCorrelationTypeModuleSpec.hpp +2 -2
- package/nitrogen/generated/shared/c++/HybridHeartbeatSeriesModuleSpec.hpp +3 -3
- package/nitrogen/generated/shared/c++/HybridQuantityTypeModuleSpec.hpp +3 -3
- package/nitrogen/generated/shared/c++/HybridStateOfMindModuleSpec.hpp +3 -3
- package/nitrogen/generated/shared/c++/HybridWorkoutProxySpec.cpp +6 -4
- package/nitrogen/generated/shared/c++/HybridWorkoutProxySpec.hpp +18 -9
- package/nitrogen/generated/shared/c++/HybridWorkoutsModuleSpec.hpp +4 -4
- package/nitrogen/generated/shared/c++/IdentifierWithUnit.hpp +4 -6
- package/nitrogen/generated/shared/c++/IntervalComponents.hpp +4 -6
- package/nitrogen/generated/shared/c++/LocationForSaving.hpp +4 -6
- package/nitrogen/generated/shared/c++/ObjectTypeIdentifier.hpp +397 -399
- package/nitrogen/generated/shared/c++/OnChangeCallbackArgs.hpp +8 -10
- package/nitrogen/generated/shared/c++/PredicateForWorkoutsAnd.hpp +9 -11
- package/nitrogen/generated/shared/c++/PredicateForWorkoutsOr.hpp +9 -11
- package/nitrogen/generated/shared/c++/PredicateFromWorkout.hpp +6 -8
- package/nitrogen/generated/shared/c++/PredicateWithMetadataKey.hpp +9 -11
- package/nitrogen/generated/shared/c++/PredicateWithMetadataOperator.hpp +11 -13
- package/nitrogen/generated/shared/c++/PredicateWithStartAndEnd.hpp +5 -7
- package/nitrogen/generated/shared/c++/PredicateWithUUID.hpp +4 -6
- package/nitrogen/generated/shared/c++/PredicateWithUUIDs.hpp +5 -7
- package/nitrogen/generated/shared/c++/Quantity.hpp +4 -6
- package/nitrogen/generated/shared/c++/QuantityDateInterval.hpp +4 -6
- package/nitrogen/generated/shared/c++/QuantitySample.hpp +14 -16
- package/nitrogen/generated/shared/c++/QuantitySampleForSaving.hpp +11 -13
- package/nitrogen/generated/shared/c++/QuantitySamplesWithAnchorResponse.hpp +11 -13
- package/nitrogen/generated/shared/c++/QuantityTypeIdentifier.hpp +241 -243
- package/nitrogen/generated/shared/c++/QueryOptionsWithAnchor.hpp +9 -11
- package/nitrogen/generated/shared/c++/QueryOptionsWithAnchorAndUnit.hpp +9 -11
- package/nitrogen/generated/shared/c++/QueryOptionsWithSortOrder.hpp +8 -10
- package/nitrogen/generated/shared/c++/QueryOptionsWithSortOrderAndUnit.hpp +9 -11
- package/nitrogen/generated/shared/c++/QueryStatisticsResponse.hpp +26 -28
- package/nitrogen/generated/shared/c++/QueryWorkoutSamplesWithAnchorResponse.hpp +10 -12
- package/nitrogen/generated/shared/c++/SampleTypeIdentifier.hpp +383 -385
- package/nitrogen/generated/shared/c++/SampleTypeIdentifierWriteable.hpp +373 -375
- package/nitrogen/generated/shared/c++/Source.hpp +4 -6
- package/nitrogen/generated/shared/c++/SourceRevision.hpp +7 -9
- package/nitrogen/generated/shared/c++/StateOfMindAssociation.hpp +10 -12
- package/nitrogen/generated/shared/c++/StateOfMindKind.hpp +14 -13
- package/nitrogen/generated/shared/c++/StateOfMindLabel.hpp +10 -12
- package/nitrogen/generated/shared/c++/StateOfMindSample.hpp +24 -26
- package/nitrogen/generated/shared/c++/StateOfMindValenceClassification.hpp +10 -12
- package/nitrogen/generated/shared/c++/StatisticsOptions.hpp +17 -19
- package/nitrogen/generated/shared/c++/StatisticsQueryOptions.hpp +9 -11
- package/nitrogen/generated/shared/c++/UpdateFrequency.hpp +10 -12
- package/nitrogen/generated/shared/c++/WheelchairUse.hpp +9 -11
- package/nitrogen/generated/shared/c++/WorkoutActivity.hpp +4 -6
- package/nitrogen/generated/shared/c++/WorkoutActivityType.hpp +96 -13
- package/nitrogen/generated/shared/c++/WorkoutActivityTypePredicate.hpp +7 -9
- package/nitrogen/generated/shared/c++/WorkoutConfiguration.hpp +11 -13
- package/nitrogen/generated/shared/c++/WorkoutDurationPredicate.hpp +7 -9
- package/nitrogen/generated/shared/c++/WorkoutEvent.hpp +7 -9
- package/nitrogen/generated/shared/c++/WorkoutEventType.hpp +10 -12
- package/nitrogen/generated/shared/c++/WorkoutPlan.hpp +7 -9
- package/nitrogen/generated/shared/c++/WorkoutQueryOptions.hpp +10 -21
- package/nitrogen/generated/shared/c++/WorkoutQueryOptionsWithAnchor.hpp +11 -21
- package/nitrogen/generated/shared/c++/WorkoutRoute.hpp +9 -11
- package/nitrogen/generated/shared/c++/WorkoutRouteLocation.hpp +4 -6
- package/nitrogen/generated/shared/c++/WorkoutSample.hpp +25 -43
- package/nitrogen/generated/shared/c++/WorkoutSessionLocationType.hpp +10 -12
- package/nitrogen/generated/shared/c++/WorkoutTotals.hpp +4 -6
- package/package.json +11 -11
- package/src/hooks/useMostRecentWorkout.ts +3 -17
- package/src/hooks/useWorkoutById.ts +1 -4
- package/src/specs/WorkoutProxy.nitro.ts +18 -1
- package/src/types/Workouts.ts +0 -8
- package/src/utils/getMostRecentWorkout.ts +1 -6
- package/src/utils/getWorkoutById.ts +1 -6
|
@@ -31,56 +31,56 @@
|
|
|
31
31
|
HybridObjectRegistry::registerHybridObjectConstructor(
|
|
32
32
|
"WorkoutsModule",
|
|
33
33
|
[]() -> std::shared_ptr<HybridObject> {
|
|
34
|
-
std::shared_ptr<
|
|
34
|
+
std::shared_ptr<HybridWorkoutsModuleSpec> hybridObject = ReactNativeHealthkit::ReactNativeHealthkitAutolinking::createWorkoutsModule();
|
|
35
35
|
return hybridObject;
|
|
36
36
|
}
|
|
37
37
|
);
|
|
38
38
|
HybridObjectRegistry::registerHybridObjectConstructor(
|
|
39
39
|
"CoreModule",
|
|
40
40
|
[]() -> std::shared_ptr<HybridObject> {
|
|
41
|
-
std::shared_ptr<
|
|
41
|
+
std::shared_ptr<HybridCoreModuleSpec> hybridObject = ReactNativeHealthkit::ReactNativeHealthkitAutolinking::createCoreModule();
|
|
42
42
|
return hybridObject;
|
|
43
43
|
}
|
|
44
44
|
);
|
|
45
45
|
HybridObjectRegistry::registerHybridObjectConstructor(
|
|
46
46
|
"CharacteristicTypeModule",
|
|
47
47
|
[]() -> std::shared_ptr<HybridObject> {
|
|
48
|
-
std::shared_ptr<
|
|
48
|
+
std::shared_ptr<HybridCharacteristicTypeModuleSpec> hybridObject = ReactNativeHealthkit::ReactNativeHealthkitAutolinking::createCharacteristicTypeModule();
|
|
49
49
|
return hybridObject;
|
|
50
50
|
}
|
|
51
51
|
);
|
|
52
52
|
HybridObjectRegistry::registerHybridObjectConstructor(
|
|
53
53
|
"QuantityTypeModule",
|
|
54
54
|
[]() -> std::shared_ptr<HybridObject> {
|
|
55
|
-
std::shared_ptr<
|
|
55
|
+
std::shared_ptr<HybridQuantityTypeModuleSpec> hybridObject = ReactNativeHealthkit::ReactNativeHealthkitAutolinking::createQuantityTypeModule();
|
|
56
56
|
return hybridObject;
|
|
57
57
|
}
|
|
58
58
|
);
|
|
59
59
|
HybridObjectRegistry::registerHybridObjectConstructor(
|
|
60
60
|
"CategoryTypeModule",
|
|
61
61
|
[]() -> std::shared_ptr<HybridObject> {
|
|
62
|
-
std::shared_ptr<
|
|
62
|
+
std::shared_ptr<HybridCategoryTypeModuleSpec> hybridObject = ReactNativeHealthkit::ReactNativeHealthkitAutolinking::createCategoryTypeModule();
|
|
63
63
|
return hybridObject;
|
|
64
64
|
}
|
|
65
65
|
);
|
|
66
66
|
HybridObjectRegistry::registerHybridObjectConstructor(
|
|
67
67
|
"CorrelationTypeModule",
|
|
68
68
|
[]() -> std::shared_ptr<HybridObject> {
|
|
69
|
-
std::shared_ptr<
|
|
69
|
+
std::shared_ptr<HybridCorrelationTypeModuleSpec> hybridObject = ReactNativeHealthkit::ReactNativeHealthkitAutolinking::createCorrelationTypeModule();
|
|
70
70
|
return hybridObject;
|
|
71
71
|
}
|
|
72
72
|
);
|
|
73
73
|
HybridObjectRegistry::registerHybridObjectConstructor(
|
|
74
74
|
"HeartbeatSeriesModule",
|
|
75
75
|
[]() -> std::shared_ptr<HybridObject> {
|
|
76
|
-
std::shared_ptr<
|
|
76
|
+
std::shared_ptr<HybridHeartbeatSeriesModuleSpec> hybridObject = ReactNativeHealthkit::ReactNativeHealthkitAutolinking::createHeartbeatSeriesModule();
|
|
77
77
|
return hybridObject;
|
|
78
78
|
}
|
|
79
79
|
);
|
|
80
80
|
HybridObjectRegistry::registerHybridObjectConstructor(
|
|
81
81
|
"StateOfMindModule",
|
|
82
82
|
[]() -> std::shared_ptr<HybridObject> {
|
|
83
|
-
std::shared_ptr<
|
|
83
|
+
std::shared_ptr<HybridStateOfMindModuleSpec> hybridObject = ReactNativeHealthkit::ReactNativeHealthkitAutolinking::createStateOfMindModule();
|
|
84
84
|
return hybridObject;
|
|
85
85
|
}
|
|
86
86
|
);
|
|
@@ -15,9 +15,9 @@ public final class ReactNativeHealthkitAutolinking {
|
|
|
15
15
|
* This is generated by Nitrogen and will initialize the class specified
|
|
16
16
|
* in the `"autolinking"` property of `nitro.json` (in this case, `WorkoutsModule`).
|
|
17
17
|
*/
|
|
18
|
-
public static func createWorkoutsModule() -> bridge.
|
|
18
|
+
public static func createWorkoutsModule() -> bridge.std__shared_ptr_HybridWorkoutsModuleSpec_ {
|
|
19
19
|
let hybridObject = WorkoutsModule()
|
|
20
|
-
return { () -> bridge.
|
|
20
|
+
return { () -> bridge.std__shared_ptr_HybridWorkoutsModuleSpec_ in
|
|
21
21
|
let __cxxWrapped = hybridObject.getCxxWrapper()
|
|
22
22
|
return __cxxWrapped.getCxxPart()
|
|
23
23
|
}()
|
|
@@ -30,9 +30,9 @@ public final class ReactNativeHealthkitAutolinking {
|
|
|
30
30
|
* This is generated by Nitrogen and will initialize the class specified
|
|
31
31
|
* in the `"autolinking"` property of `nitro.json` (in this case, `CoreModule`).
|
|
32
32
|
*/
|
|
33
|
-
public static func createCoreModule() -> bridge.
|
|
33
|
+
public static func createCoreModule() -> bridge.std__shared_ptr_HybridCoreModuleSpec_ {
|
|
34
34
|
let hybridObject = CoreModule()
|
|
35
|
-
return { () -> bridge.
|
|
35
|
+
return { () -> bridge.std__shared_ptr_HybridCoreModuleSpec_ in
|
|
36
36
|
let __cxxWrapped = hybridObject.getCxxWrapper()
|
|
37
37
|
return __cxxWrapped.getCxxPart()
|
|
38
38
|
}()
|
|
@@ -45,9 +45,9 @@ public final class ReactNativeHealthkitAutolinking {
|
|
|
45
45
|
* This is generated by Nitrogen and will initialize the class specified
|
|
46
46
|
* in the `"autolinking"` property of `nitro.json` (in this case, `CharacteristicTypeModule`).
|
|
47
47
|
*/
|
|
48
|
-
public static func createCharacteristicTypeModule() -> bridge.
|
|
48
|
+
public static func createCharacteristicTypeModule() -> bridge.std__shared_ptr_HybridCharacteristicTypeModuleSpec_ {
|
|
49
49
|
let hybridObject = CharacteristicTypeModule()
|
|
50
|
-
return { () -> bridge.
|
|
50
|
+
return { () -> bridge.std__shared_ptr_HybridCharacteristicTypeModuleSpec_ in
|
|
51
51
|
let __cxxWrapped = hybridObject.getCxxWrapper()
|
|
52
52
|
return __cxxWrapped.getCxxPart()
|
|
53
53
|
}()
|
|
@@ -60,9 +60,9 @@ public final class ReactNativeHealthkitAutolinking {
|
|
|
60
60
|
* This is generated by Nitrogen and will initialize the class specified
|
|
61
61
|
* in the `"autolinking"` property of `nitro.json` (in this case, `QuantityTypeModule`).
|
|
62
62
|
*/
|
|
63
|
-
public static func createQuantityTypeModule() -> bridge.
|
|
63
|
+
public static func createQuantityTypeModule() -> bridge.std__shared_ptr_HybridQuantityTypeModuleSpec_ {
|
|
64
64
|
let hybridObject = QuantityTypeModule()
|
|
65
|
-
return { () -> bridge.
|
|
65
|
+
return { () -> bridge.std__shared_ptr_HybridQuantityTypeModuleSpec_ in
|
|
66
66
|
let __cxxWrapped = hybridObject.getCxxWrapper()
|
|
67
67
|
return __cxxWrapped.getCxxPart()
|
|
68
68
|
}()
|
|
@@ -75,9 +75,9 @@ public final class ReactNativeHealthkitAutolinking {
|
|
|
75
75
|
* This is generated by Nitrogen and will initialize the class specified
|
|
76
76
|
* in the `"autolinking"` property of `nitro.json` (in this case, `CategoryTypeModule`).
|
|
77
77
|
*/
|
|
78
|
-
public static func createCategoryTypeModule() -> bridge.
|
|
78
|
+
public static func createCategoryTypeModule() -> bridge.std__shared_ptr_HybridCategoryTypeModuleSpec_ {
|
|
79
79
|
let hybridObject = CategoryTypeModule()
|
|
80
|
-
return { () -> bridge.
|
|
80
|
+
return { () -> bridge.std__shared_ptr_HybridCategoryTypeModuleSpec_ in
|
|
81
81
|
let __cxxWrapped = hybridObject.getCxxWrapper()
|
|
82
82
|
return __cxxWrapped.getCxxPart()
|
|
83
83
|
}()
|
|
@@ -90,9 +90,9 @@ public final class ReactNativeHealthkitAutolinking {
|
|
|
90
90
|
* This is generated by Nitrogen and will initialize the class specified
|
|
91
91
|
* in the `"autolinking"` property of `nitro.json` (in this case, `CorrelationTypeModule`).
|
|
92
92
|
*/
|
|
93
|
-
public static func createCorrelationTypeModule() -> bridge.
|
|
93
|
+
public static func createCorrelationTypeModule() -> bridge.std__shared_ptr_HybridCorrelationTypeModuleSpec_ {
|
|
94
94
|
let hybridObject = CorrelationTypeModule()
|
|
95
|
-
return { () -> bridge.
|
|
95
|
+
return { () -> bridge.std__shared_ptr_HybridCorrelationTypeModuleSpec_ in
|
|
96
96
|
let __cxxWrapped = hybridObject.getCxxWrapper()
|
|
97
97
|
return __cxxWrapped.getCxxPart()
|
|
98
98
|
}()
|
|
@@ -105,9 +105,9 @@ public final class ReactNativeHealthkitAutolinking {
|
|
|
105
105
|
* This is generated by Nitrogen and will initialize the class specified
|
|
106
106
|
* in the `"autolinking"` property of `nitro.json` (in this case, `HeartbeatSeriesModule`).
|
|
107
107
|
*/
|
|
108
|
-
public static func createHeartbeatSeriesModule() -> bridge.
|
|
108
|
+
public static func createHeartbeatSeriesModule() -> bridge.std__shared_ptr_HybridHeartbeatSeriesModuleSpec_ {
|
|
109
109
|
let hybridObject = HeartbeatSeriesModule()
|
|
110
|
-
return { () -> bridge.
|
|
110
|
+
return { () -> bridge.std__shared_ptr_HybridHeartbeatSeriesModuleSpec_ in
|
|
111
111
|
let __cxxWrapped = hybridObject.getCxxWrapper()
|
|
112
112
|
return __cxxWrapped.getCxxPart()
|
|
113
113
|
}()
|
|
@@ -120,9 +120,9 @@ public final class ReactNativeHealthkitAutolinking {
|
|
|
120
120
|
* This is generated by Nitrogen and will initialize the class specified
|
|
121
121
|
* in the `"autolinking"` property of `nitro.json` (in this case, `StateOfMindModule`).
|
|
122
122
|
*/
|
|
123
|
-
public static func createStateOfMindModule() -> bridge.
|
|
123
|
+
public static func createStateOfMindModule() -> bridge.std__shared_ptr_HybridStateOfMindModuleSpec_ {
|
|
124
124
|
let hybridObject = StateOfMindModule()
|
|
125
|
-
return { () -> bridge.
|
|
125
|
+
return { () -> bridge.std__shared_ptr_HybridStateOfMindModuleSpec_ in
|
|
126
126
|
let __cxxWrapped = hybridObject.getCxxWrapper()
|
|
127
127
|
return __cxxWrapped.getCxxPart()
|
|
128
128
|
}()
|
|
@@ -55,16 +55,15 @@ namespace margelo::nitro::healthkit { struct QueryOptionsWithAnchor; }
|
|
|
55
55
|
#include "CategoryTypeIdentifier.hpp"
|
|
56
56
|
#include <chrono>
|
|
57
57
|
#include <NitroModules/AnyMap.hpp>
|
|
58
|
-
#include <vector>
|
|
59
58
|
#include "CategorySample.hpp"
|
|
59
|
+
#include <vector>
|
|
60
60
|
#include <string>
|
|
61
|
-
#include <optional>
|
|
62
61
|
#include "Device.hpp"
|
|
62
|
+
#include <optional>
|
|
63
63
|
#include "SourceRevision.hpp"
|
|
64
64
|
#include <memory>
|
|
65
65
|
#include "HybridSourceProxySpec.hpp"
|
|
66
66
|
#include "QueryOptionsWithSortOrder.hpp"
|
|
67
|
-
#include <variant>
|
|
68
67
|
#include "PredicateWithUUID.hpp"
|
|
69
68
|
#include "PredicateWithUUIDs.hpp"
|
|
70
69
|
#include "PredicateWithMetadataKey.hpp"
|
|
@@ -72,6 +71,7 @@ namespace margelo::nitro::healthkit { struct QueryOptionsWithAnchor; }
|
|
|
72
71
|
#include "PredicateFromWorkout.hpp"
|
|
73
72
|
#include "FilterForSamplesAnd.hpp"
|
|
74
73
|
#include "FilterForSamplesOr.hpp"
|
|
74
|
+
#include <variant>
|
|
75
75
|
#include "PredicateWithMetadataOperator.hpp"
|
|
76
76
|
#include "HybridWorkoutProxySpec.hpp"
|
|
77
77
|
#include "CategorySamplesWithAnchorResponse.hpp"
|
|
@@ -106,10 +106,12 @@ namespace margelo::nitro::healthkit {
|
|
|
106
106
|
}
|
|
107
107
|
|
|
108
108
|
public:
|
|
109
|
-
// Get memory pressure
|
|
110
109
|
inline size_t getExternalMemorySize() noexcept override {
|
|
111
110
|
return _swiftPart.getMemorySize();
|
|
112
111
|
}
|
|
112
|
+
void dispose() noexcept override {
|
|
113
|
+
_swiftPart.dispose();
|
|
114
|
+
}
|
|
113
115
|
|
|
114
116
|
public:
|
|
115
117
|
// Properties
|
|
@@ -22,8 +22,8 @@ namespace margelo::nitro::healthkit { enum class FitzpatrickSkinType; }
|
|
|
22
22
|
namespace margelo::nitro::healthkit { enum class WheelchairUse; }
|
|
23
23
|
|
|
24
24
|
#include "BloodType.hpp"
|
|
25
|
-
#include <optional>
|
|
26
25
|
#include <chrono>
|
|
26
|
+
#include <optional>
|
|
27
27
|
#include "BiologicalSex.hpp"
|
|
28
28
|
#include "FitzpatrickSkinType.hpp"
|
|
29
29
|
#include "WheelchairUse.hpp"
|
|
@@ -57,10 +57,12 @@ namespace margelo::nitro::healthkit {
|
|
|
57
57
|
}
|
|
58
58
|
|
|
59
59
|
public:
|
|
60
|
-
// Get memory pressure
|
|
61
60
|
inline size_t getExternalMemorySize() noexcept override {
|
|
62
61
|
return _swiftPart.getMemorySize();
|
|
63
62
|
}
|
|
63
|
+
void dispose() noexcept override {
|
|
64
|
+
_swiftPart.dispose();
|
|
65
|
+
}
|
|
64
66
|
|
|
65
67
|
public:
|
|
66
68
|
// Properties
|
|
@@ -54,20 +54,19 @@ namespace margelo::nitro::healthkit { class HybridWorkoutProxySpec; }
|
|
|
54
54
|
#include <NitroModules/Promise.hpp>
|
|
55
55
|
#include "ObjectTypeIdentifier.hpp"
|
|
56
56
|
#include "UpdateFrequency.hpp"
|
|
57
|
-
#include <vector>
|
|
58
57
|
#include "IdentifierWithUnit.hpp"
|
|
58
|
+
#include <vector>
|
|
59
59
|
#include <string>
|
|
60
60
|
#include "QuantityTypeIdentifier.hpp"
|
|
61
61
|
#include <optional>
|
|
62
62
|
#include <memory>
|
|
63
63
|
#include "HybridSourceProxySpec.hpp"
|
|
64
64
|
#include "SampleTypeIdentifier.hpp"
|
|
65
|
-
#include <functional>
|
|
66
65
|
#include "OnChangeCallbackArgs.hpp"
|
|
66
|
+
#include <functional>
|
|
67
67
|
#include "AuthorizationStatus.hpp"
|
|
68
68
|
#include "AuthorizationRequestStatus.hpp"
|
|
69
69
|
#include "SampleTypeIdentifierWriteable.hpp"
|
|
70
|
-
#include <variant>
|
|
71
70
|
#include "PredicateWithUUID.hpp"
|
|
72
71
|
#include "PredicateWithUUIDs.hpp"
|
|
73
72
|
#include "PredicateWithMetadataKey.hpp"
|
|
@@ -75,6 +74,7 @@ namespace margelo::nitro::healthkit { class HybridWorkoutProxySpec; }
|
|
|
75
74
|
#include "PredicateFromWorkout.hpp"
|
|
76
75
|
#include "FilterForSamplesAnd.hpp"
|
|
77
76
|
#include "FilterForSamplesOr.hpp"
|
|
77
|
+
#include <variant>
|
|
78
78
|
#include "PredicateWithMetadataOperator.hpp"
|
|
79
79
|
#include <chrono>
|
|
80
80
|
#include "HybridWorkoutProxySpec.hpp"
|
|
@@ -108,10 +108,12 @@ namespace margelo::nitro::healthkit {
|
|
|
108
108
|
}
|
|
109
109
|
|
|
110
110
|
public:
|
|
111
|
-
// Get memory pressure
|
|
112
111
|
inline size_t getExternalMemorySize() noexcept override {
|
|
113
112
|
return _swiftPart.getMemorySize();
|
|
114
113
|
}
|
|
114
|
+
void dispose() noexcept override {
|
|
115
|
+
_swiftPart.dispose();
|
|
116
|
+
}
|
|
115
117
|
|
|
116
118
|
public:
|
|
117
119
|
// Properties
|
|
@@ -183,7 +185,7 @@ namespace margelo::nitro::healthkit {
|
|
|
183
185
|
auto __value = std::move(__result.value());
|
|
184
186
|
return __value;
|
|
185
187
|
}
|
|
186
|
-
inline std::shared_ptr<Promise<std::vector<std::shared_ptr<
|
|
188
|
+
inline std::shared_ptr<Promise<std::vector<std::shared_ptr<HybridSourceProxySpec>>>> querySources(SampleTypeIdentifier identifier) override {
|
|
187
189
|
auto __result = _swiftPart.querySources(static_cast<int>(identifier));
|
|
188
190
|
if (__result.hasError()) [[unlikely]] {
|
|
189
191
|
std::rethrow_exception(__result.error());
|
|
@@ -39,15 +39,15 @@ namespace margelo::nitro::healthkit { struct Device; }
|
|
|
39
39
|
|
|
40
40
|
#include <NitroModules/Promise.hpp>
|
|
41
41
|
#include "CorrelationTypeIdentifier.hpp"
|
|
42
|
-
#include <vector>
|
|
43
|
-
#include <variant>
|
|
44
42
|
#include "CategorySampleForSaving.hpp"
|
|
45
43
|
#include "QuantitySampleForSaving.hpp"
|
|
44
|
+
#include <variant>
|
|
45
|
+
#include <vector>
|
|
46
46
|
#include <chrono>
|
|
47
47
|
#include "CategoryTypeIdentifier.hpp"
|
|
48
48
|
#include <NitroModules/AnyMap.hpp>
|
|
49
|
-
#include <optional>
|
|
50
49
|
#include "SourceRevision.hpp"
|
|
50
|
+
#include <optional>
|
|
51
51
|
#include <memory>
|
|
52
52
|
#include "HybridSourceProxySpec.hpp"
|
|
53
53
|
#include <string>
|
|
@@ -85,10 +85,12 @@ namespace margelo::nitro::healthkit {
|
|
|
85
85
|
}
|
|
86
86
|
|
|
87
87
|
public:
|
|
88
|
-
// Get memory pressure
|
|
89
88
|
inline size_t getExternalMemorySize() noexcept override {
|
|
90
89
|
return _swiftPart.getMemorySize();
|
|
91
90
|
}
|
|
91
|
+
void dispose() noexcept override {
|
|
92
|
+
_swiftPart.dispose();
|
|
93
|
+
}
|
|
92
94
|
|
|
93
95
|
public:
|
|
94
96
|
// Properties
|
|
@@ -51,12 +51,12 @@ namespace margelo::nitro::healthkit { struct DeletedSample; }
|
|
|
51
51
|
// Forward declaration of `QueryOptionsWithAnchor` to properly resolve imports.
|
|
52
52
|
namespace margelo::nitro::healthkit { struct QueryOptionsWithAnchor; }
|
|
53
53
|
|
|
54
|
-
#include <NitroModules/Promise.hpp>
|
|
55
|
-
#include <vector>
|
|
56
54
|
#include "HeartbeatSeriesSample.hpp"
|
|
55
|
+
#include <vector>
|
|
56
|
+
#include <NitroModules/Promise.hpp>
|
|
57
57
|
#include <string>
|
|
58
|
-
#include <optional>
|
|
59
58
|
#include "Device.hpp"
|
|
59
|
+
#include <optional>
|
|
60
60
|
#include <chrono>
|
|
61
61
|
#include "Heartbeat.hpp"
|
|
62
62
|
#include <NitroModules/AnyMap.hpp>
|
|
@@ -64,7 +64,6 @@ namespace margelo::nitro::healthkit { struct QueryOptionsWithAnchor; }
|
|
|
64
64
|
#include <memory>
|
|
65
65
|
#include "HybridSourceProxySpec.hpp"
|
|
66
66
|
#include "QueryOptionsWithSortOrder.hpp"
|
|
67
|
-
#include <variant>
|
|
68
67
|
#include "PredicateWithUUID.hpp"
|
|
69
68
|
#include "PredicateWithUUIDs.hpp"
|
|
70
69
|
#include "PredicateWithMetadataKey.hpp"
|
|
@@ -72,6 +71,7 @@ namespace margelo::nitro::healthkit { struct QueryOptionsWithAnchor; }
|
|
|
72
71
|
#include "PredicateFromWorkout.hpp"
|
|
73
72
|
#include "FilterForSamplesAnd.hpp"
|
|
74
73
|
#include "FilterForSamplesOr.hpp"
|
|
74
|
+
#include <variant>
|
|
75
75
|
#include "PredicateWithMetadataOperator.hpp"
|
|
76
76
|
#include "HybridWorkoutProxySpec.hpp"
|
|
77
77
|
#include "HeartbeatSeriesSamplesWithAnchorResponse.hpp"
|
|
@@ -106,10 +106,12 @@ namespace margelo::nitro::healthkit {
|
|
|
106
106
|
}
|
|
107
107
|
|
|
108
108
|
public:
|
|
109
|
-
// Get memory pressure
|
|
110
109
|
inline size_t getExternalMemorySize() noexcept override {
|
|
111
110
|
return _swiftPart.getMemorySize();
|
|
112
111
|
}
|
|
112
|
+
void dispose() noexcept override {
|
|
113
|
+
_swiftPart.dispose();
|
|
114
|
+
}
|
|
113
115
|
|
|
114
116
|
public:
|
|
115
117
|
// Properties
|
|
@@ -68,7 +68,6 @@ namespace margelo::nitro::healthkit { struct QueryOptionsWithAnchorAndUnit; }
|
|
|
68
68
|
#include <NitroModules/Promise.hpp>
|
|
69
69
|
#include <chrono>
|
|
70
70
|
#include <NitroModules/AnyMap.hpp>
|
|
71
|
-
#include <variant>
|
|
72
71
|
#include "PredicateWithUUID.hpp"
|
|
73
72
|
#include "PredicateWithUUIDs.hpp"
|
|
74
73
|
#include "PredicateWithMetadataKey.hpp"
|
|
@@ -76,9 +75,10 @@ namespace margelo::nitro::healthkit { struct QueryOptionsWithAnchorAndUnit; }
|
|
|
76
75
|
#include "PredicateFromWorkout.hpp"
|
|
77
76
|
#include "FilterForSamplesAnd.hpp"
|
|
78
77
|
#include "FilterForSamplesOr.hpp"
|
|
78
|
+
#include <variant>
|
|
79
79
|
#include <vector>
|
|
80
|
-
#include <optional>
|
|
81
80
|
#include "PredicateWithMetadataOperator.hpp"
|
|
81
|
+
#include <optional>
|
|
82
82
|
#include <memory>
|
|
83
83
|
#include "HybridWorkoutProxySpec.hpp"
|
|
84
84
|
#include "QuantitySample.hpp"
|
|
@@ -124,10 +124,12 @@ namespace margelo::nitro::healthkit {
|
|
|
124
124
|
}
|
|
125
125
|
|
|
126
126
|
public:
|
|
127
|
-
// Get memory pressure
|
|
128
127
|
inline size_t getExternalMemorySize() noexcept override {
|
|
129
128
|
return _swiftPart.getMemorySize();
|
|
130
129
|
}
|
|
130
|
+
void dispose() noexcept override {
|
|
131
|
+
_swiftPart.dispose();
|
|
132
|
+
}
|
|
131
133
|
|
|
132
134
|
public:
|
|
133
135
|
// Properties
|
|
@@ -47,10 +47,12 @@ namespace margelo::nitro::healthkit {
|
|
|
47
47
|
}
|
|
48
48
|
|
|
49
49
|
public:
|
|
50
|
-
// Get memory pressure
|
|
51
50
|
inline size_t getExternalMemorySize() noexcept override {
|
|
52
51
|
return _swiftPart.getMemorySize();
|
|
53
52
|
}
|
|
53
|
+
void dispose() noexcept override {
|
|
54
|
+
_swiftPart.dispose();
|
|
55
|
+
}
|
|
54
56
|
|
|
55
57
|
public:
|
|
56
58
|
// Properties
|
|
@@ -51,12 +51,12 @@ namespace margelo::nitro::healthkit { enum class PredicateWithMetadataOperator;
|
|
|
51
51
|
// Forward declaration of `HybridWorkoutProxySpec` to properly resolve imports.
|
|
52
52
|
namespace margelo::nitro::healthkit { class HybridWorkoutProxySpec; }
|
|
53
53
|
|
|
54
|
-
#include <NitroModules/Promise.hpp>
|
|
55
|
-
#include <vector>
|
|
56
54
|
#include "StateOfMindSample.hpp"
|
|
55
|
+
#include <vector>
|
|
56
|
+
#include <NitroModules/Promise.hpp>
|
|
57
57
|
#include <string>
|
|
58
|
-
#include <optional>
|
|
59
58
|
#include "Device.hpp"
|
|
59
|
+
#include <optional>
|
|
60
60
|
#include <chrono>
|
|
61
61
|
#include <NitroModules/AnyMap.hpp>
|
|
62
62
|
#include "SourceRevision.hpp"
|
|
@@ -67,7 +67,6 @@ namespace margelo::nitro::healthkit { class HybridWorkoutProxySpec; }
|
|
|
67
67
|
#include "StateOfMindAssociation.hpp"
|
|
68
68
|
#include "StateOfMindLabel.hpp"
|
|
69
69
|
#include "QueryOptionsWithSortOrder.hpp"
|
|
70
|
-
#include <variant>
|
|
71
70
|
#include "PredicateWithUUID.hpp"
|
|
72
71
|
#include "PredicateWithUUIDs.hpp"
|
|
73
72
|
#include "PredicateWithMetadataKey.hpp"
|
|
@@ -75,6 +74,7 @@ namespace margelo::nitro::healthkit { class HybridWorkoutProxySpec; }
|
|
|
75
74
|
#include "PredicateFromWorkout.hpp"
|
|
76
75
|
#include "FilterForSamplesAnd.hpp"
|
|
77
76
|
#include "FilterForSamplesOr.hpp"
|
|
77
|
+
#include <variant>
|
|
78
78
|
#include "PredicateWithMetadataOperator.hpp"
|
|
79
79
|
#include "HybridWorkoutProxySpec.hpp"
|
|
80
80
|
|
|
@@ -106,10 +106,12 @@ namespace margelo::nitro::healthkit {
|
|
|
106
106
|
}
|
|
107
107
|
|
|
108
108
|
public:
|
|
109
|
-
// Get memory pressure
|
|
110
109
|
inline size_t getExternalMemorySize() noexcept override {
|
|
111
110
|
return _swiftPart.getMemorySize();
|
|
112
111
|
}
|
|
112
|
+
void dispose() noexcept override {
|
|
113
|
+
_swiftPart.dispose();
|
|
114
|
+
}
|
|
113
115
|
|
|
114
116
|
public:
|
|
115
117
|
// Properties
|
|
@@ -12,12 +12,12 @@
|
|
|
12
12
|
// Forward declaration of `HybridWorkoutProxySpec_cxx` to properly resolve imports.
|
|
13
13
|
namespace ReactNativeHealthkit { class HybridWorkoutProxySpec_cxx; }
|
|
14
14
|
|
|
15
|
+
// Forward declaration of `Quantity` to properly resolve imports.
|
|
16
|
+
namespace margelo::nitro::healthkit { struct Quantity; }
|
|
15
17
|
// Forward declaration of `Device` to properly resolve imports.
|
|
16
18
|
namespace margelo::nitro::healthkit { struct Device; }
|
|
17
19
|
// Forward declaration of `WorkoutActivityType` to properly resolve imports.
|
|
18
20
|
namespace margelo::nitro::healthkit { enum class WorkoutActivityType; }
|
|
19
|
-
// Forward declaration of `Quantity` to properly resolve imports.
|
|
20
|
-
namespace margelo::nitro::healthkit { struct Quantity; }
|
|
21
21
|
// Forward declaration of `AnyMap` to properly resolve imports.
|
|
22
22
|
namespace NitroModules { class AnyMap; }
|
|
23
23
|
// Forward declaration of `SourceRevision` to properly resolve imports.
|
|
@@ -40,19 +40,25 @@ namespace margelo::nitro::healthkit { struct WorkoutPlan; }
|
|
|
40
40
|
namespace margelo::nitro::healthkit { struct WorkoutRoute; }
|
|
41
41
|
// Forward declaration of `WorkoutRouteLocation` to properly resolve imports.
|
|
42
42
|
namespace margelo::nitro::healthkit { struct WorkoutRouteLocation; }
|
|
43
|
+
// Forward declaration of `QueryStatisticsResponse` to properly resolve imports.
|
|
44
|
+
namespace margelo::nitro::healthkit { struct QueryStatisticsResponse; }
|
|
45
|
+
// Forward declaration of `QuantityDateInterval` to properly resolve imports.
|
|
46
|
+
namespace margelo::nitro::healthkit { struct QuantityDateInterval; }
|
|
47
|
+
// Forward declaration of `QuantityTypeIdentifier` to properly resolve imports.
|
|
48
|
+
namespace margelo::nitro::healthkit { enum class QuantityTypeIdentifier; }
|
|
43
49
|
|
|
44
|
-
#include
|
|
50
|
+
#include "Quantity.hpp"
|
|
45
51
|
#include <optional>
|
|
52
|
+
#include <string>
|
|
46
53
|
#include "Device.hpp"
|
|
47
54
|
#include "WorkoutActivityType.hpp"
|
|
48
|
-
#include "Quantity.hpp"
|
|
49
55
|
#include <chrono>
|
|
50
56
|
#include <NitroModules/AnyMap.hpp>
|
|
51
57
|
#include "SourceRevision.hpp"
|
|
52
58
|
#include <memory>
|
|
53
59
|
#include "HybridSourceProxySpec.hpp"
|
|
54
|
-
#include <vector>
|
|
55
60
|
#include "WorkoutEvent.hpp"
|
|
61
|
+
#include <vector>
|
|
56
62
|
#include "WorkoutEventType.hpp"
|
|
57
63
|
#include "WorkoutActivity.hpp"
|
|
58
64
|
#include "WorkoutSample.hpp"
|
|
@@ -61,6 +67,10 @@ namespace margelo::nitro::healthkit { struct WorkoutRouteLocation; }
|
|
|
61
67
|
#include "WorkoutPlan.hpp"
|
|
62
68
|
#include "WorkoutRoute.hpp"
|
|
63
69
|
#include "WorkoutRouteLocation.hpp"
|
|
70
|
+
#include "QueryStatisticsResponse.hpp"
|
|
71
|
+
#include "QuantityDateInterval.hpp"
|
|
72
|
+
#include "QuantityTypeIdentifier.hpp"
|
|
73
|
+
#include <unordered_map>
|
|
64
74
|
|
|
65
75
|
#include "ReactNativeHealthkit-Swift-Cxx-Umbrella.hpp"
|
|
66
76
|
|
|
@@ -90,29 +100,15 @@ namespace margelo::nitro::healthkit {
|
|
|
90
100
|
}
|
|
91
101
|
|
|
92
102
|
public:
|
|
93
|
-
// Get memory pressure
|
|
94
103
|
inline size_t getExternalMemorySize() noexcept override {
|
|
95
104
|
return _swiftPart.getMemorySize();
|
|
96
105
|
}
|
|
106
|
+
void dispose() noexcept override {
|
|
107
|
+
_swiftPart.dispose();
|
|
108
|
+
}
|
|
97
109
|
|
|
98
110
|
public:
|
|
99
111
|
// Properties
|
|
100
|
-
inline std::string getUuid() noexcept override {
|
|
101
|
-
auto __result = _swiftPart.getUuid();
|
|
102
|
-
return __result;
|
|
103
|
-
}
|
|
104
|
-
inline std::optional<Device> getDevice() noexcept override {
|
|
105
|
-
auto __result = _swiftPart.getDevice();
|
|
106
|
-
return __result;
|
|
107
|
-
}
|
|
108
|
-
inline WorkoutActivityType getWorkoutActivityType() noexcept override {
|
|
109
|
-
auto __result = _swiftPart.getWorkoutActivityType();
|
|
110
|
-
return static_cast<WorkoutActivityType>(__result);
|
|
111
|
-
}
|
|
112
|
-
inline Quantity getDuration() noexcept override {
|
|
113
|
-
auto __result = _swiftPart.getDuration();
|
|
114
|
-
return __result;
|
|
115
|
-
}
|
|
116
112
|
inline std::optional<Quantity> getTotalDistance() noexcept override {
|
|
117
113
|
auto __result = _swiftPart.getTotalDistance();
|
|
118
114
|
return __result;
|
|
@@ -129,6 +125,22 @@ namespace margelo::nitro::healthkit {
|
|
|
129
125
|
auto __result = _swiftPart.getTotalFlightsClimbed();
|
|
130
126
|
return __result;
|
|
131
127
|
}
|
|
128
|
+
inline std::string getUuid() noexcept override {
|
|
129
|
+
auto __result = _swiftPart.getUuid();
|
|
130
|
+
return __result;
|
|
131
|
+
}
|
|
132
|
+
inline std::optional<Device> getDevice() noexcept override {
|
|
133
|
+
auto __result = _swiftPart.getDevice();
|
|
134
|
+
return __result;
|
|
135
|
+
}
|
|
136
|
+
inline WorkoutActivityType getWorkoutActivityType() noexcept override {
|
|
137
|
+
auto __result = _swiftPart.getWorkoutActivityType();
|
|
138
|
+
return static_cast<WorkoutActivityType>(__result);
|
|
139
|
+
}
|
|
140
|
+
inline Quantity getDuration() noexcept override {
|
|
141
|
+
auto __result = _swiftPart.getDuration();
|
|
142
|
+
return __result;
|
|
143
|
+
}
|
|
132
144
|
inline std::chrono::system_clock::time_point getStartDate() noexcept override {
|
|
133
145
|
auto __result = _swiftPart.getStartDate();
|
|
134
146
|
return __result;
|
|
@@ -188,6 +200,22 @@ namespace margelo::nitro::healthkit {
|
|
|
188
200
|
auto __value = std::move(__result.value());
|
|
189
201
|
return __value;
|
|
190
202
|
}
|
|
203
|
+
inline std::shared_ptr<Promise<std::optional<QueryStatisticsResponse>>> getStatistic(QuantityTypeIdentifier quantityType, const std::optional<std::string>& unitOverride) override {
|
|
204
|
+
auto __result = _swiftPart.getStatistic(static_cast<int>(quantityType), unitOverride);
|
|
205
|
+
if (__result.hasError()) [[unlikely]] {
|
|
206
|
+
std::rethrow_exception(__result.error());
|
|
207
|
+
}
|
|
208
|
+
auto __value = std::move(__result.value());
|
|
209
|
+
return __value;
|
|
210
|
+
}
|
|
211
|
+
inline std::shared_ptr<Promise<std::unordered_map<std::string, QueryStatisticsResponse>>> getAllStatistics() override {
|
|
212
|
+
auto __result = _swiftPart.getAllStatistics();
|
|
213
|
+
if (__result.hasError()) [[unlikely]] {
|
|
214
|
+
std::rethrow_exception(__result.error());
|
|
215
|
+
}
|
|
216
|
+
auto __value = std::move(__result.value());
|
|
217
|
+
return __value;
|
|
218
|
+
}
|
|
191
219
|
|
|
192
220
|
private:
|
|
193
221
|
ReactNativeHealthkit::HybridWorkoutProxySpec_cxx _swiftPart;
|
|
@@ -63,24 +63,23 @@ namespace margelo::nitro::healthkit { struct WorkoutConfiguration; }
|
|
|
63
63
|
// Forward declaration of `WorkoutSessionLocationType` to properly resolve imports.
|
|
64
64
|
namespace margelo::nitro::healthkit { enum class WorkoutSessionLocationType; }
|
|
65
65
|
|
|
66
|
-
#include <NitroModules/Promise.hpp>
|
|
67
66
|
#include <memory>
|
|
68
67
|
#include "HybridWorkoutProxySpec.hpp"
|
|
68
|
+
#include <NitroModules/Promise.hpp>
|
|
69
69
|
#include "WorkoutActivityType.hpp"
|
|
70
|
-
#include <vector>
|
|
71
70
|
#include "QuantitySampleForSaving.hpp"
|
|
71
|
+
#include <vector>
|
|
72
72
|
#include <chrono>
|
|
73
73
|
#include "QuantityTypeIdentifier.hpp"
|
|
74
74
|
#include <string>
|
|
75
75
|
#include <NitroModules/AnyMap.hpp>
|
|
76
|
-
#include <optional>
|
|
77
76
|
#include "SourceRevision.hpp"
|
|
77
|
+
#include <optional>
|
|
78
78
|
#include "HybridSourceProxySpec.hpp"
|
|
79
79
|
#include "WorkoutTotals.hpp"
|
|
80
80
|
#include "QueryWorkoutSamplesWithAnchorResponse.hpp"
|
|
81
81
|
#include "DeletedSample.hpp"
|
|
82
82
|
#include "WorkoutQueryOptionsWithAnchor.hpp"
|
|
83
|
-
#include <variant>
|
|
84
83
|
#include "PredicateWithUUID.hpp"
|
|
85
84
|
#include "PredicateWithUUIDs.hpp"
|
|
86
85
|
#include "PredicateWithMetadataKey.hpp"
|
|
@@ -90,6 +89,7 @@ namespace margelo::nitro::healthkit { enum class WorkoutSessionLocationType; }
|
|
|
90
89
|
#include "WorkoutDurationPredicate.hpp"
|
|
91
90
|
#include "PredicateForWorkoutsOr.hpp"
|
|
92
91
|
#include "PredicateForWorkoutsAnd.hpp"
|
|
92
|
+
#include <variant>
|
|
93
93
|
#include "PredicateWithMetadataOperator.hpp"
|
|
94
94
|
#include "ComparisonPredicateOperator.hpp"
|
|
95
95
|
#include "WorkoutQueryOptions.hpp"
|
|
@@ -124,10 +124,12 @@ namespace margelo::nitro::healthkit {
|
|
|
124
124
|
}
|
|
125
125
|
|
|
126
126
|
public:
|
|
127
|
-
// Get memory pressure
|
|
128
127
|
inline size_t getExternalMemorySize() noexcept override {
|
|
129
128
|
return _swiftPart.getMemorySize();
|
|
130
129
|
}
|
|
130
|
+
void dispose() noexcept override {
|
|
131
|
+
_swiftPart.dispose();
|
|
132
|
+
}
|
|
131
133
|
|
|
132
134
|
public:
|
|
133
135
|
// Properties
|
|
@@ -135,7 +137,7 @@ namespace margelo::nitro::healthkit {
|
|
|
135
137
|
|
|
136
138
|
public:
|
|
137
139
|
// Methods
|
|
138
|
-
inline std::shared_ptr<Promise<std::shared_ptr<
|
|
140
|
+
inline std::shared_ptr<Promise<std::shared_ptr<HybridWorkoutProxySpec>>> saveWorkoutSample(WorkoutActivityType workoutActivityType, const std::vector<QuantitySampleForSaving>& quantities, std::chrono::system_clock::time_point startDate, std::chrono::system_clock::time_point endDate, const WorkoutTotals& totals, const std::shared_ptr<AnyMap>& metadata) override {
|
|
139
141
|
auto __result = _swiftPart.saveWorkoutSample(static_cast<int>(workoutActivityType), quantities, startDate, endDate, totals, metadata);
|
|
140
142
|
if (__result.hasError()) [[unlikely]] {
|
|
141
143
|
std::rethrow_exception(__result.error());
|
|
@@ -151,7 +153,7 @@ namespace margelo::nitro::healthkit {
|
|
|
151
153
|
auto __value = std::move(__result.value());
|
|
152
154
|
return __value;
|
|
153
155
|
}
|
|
154
|
-
inline std::shared_ptr<Promise<std::vector<std::shared_ptr<
|
|
156
|
+
inline std::shared_ptr<Promise<std::vector<std::shared_ptr<HybridWorkoutProxySpec>>>> queryWorkoutSamples(const WorkoutQueryOptions& options) override {
|
|
155
157
|
auto __result = _swiftPart.queryWorkoutSamples(options);
|
|
156
158
|
if (__result.hasError()) [[unlikely]] {
|
|
157
159
|
std::rethrow_exception(__result.error());
|