@kingstinct/react-native-healthkit 12.1.2 → 12.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/ios/CategoryTypeModule.swift +49 -97
- package/ios/CharacteristicTypeModule.swift +77 -63
- package/ios/CoreModule.swift +324 -280
- package/ios/CorrelationTypeModule.swift +192 -144
- package/ios/ElectrocardiogramModule.swift +185 -194
- package/ios/HeartbeatSeriesModule.swift +123 -171
- package/ios/Helpers.swift +312 -571
- package/ios/MedicationModule.swift +259 -0
- package/ios/PredicateHelpers.swift +334 -0
- package/ios/QuantityTypeModule.swift +297 -378
- package/ios/Serializers.swift +273 -210
- package/ios/SourceProxy.swift +2 -2
- package/ios/StateOfMindModule.swift +179 -125
- package/ios/WorkoutProxy.swift +235 -112
- package/ios/WorkoutsModule.swift +214 -262
- package/lib/commonjs/healthkit.ios.js +22 -2
- package/lib/commonjs/healthkit.js +35 -5
- package/lib/commonjs/hooks/useStatisticsForQuantity.js +1 -1
- package/lib/commonjs/hooks/useSubscribeToCategorySamples.js +20 -0
- package/lib/commonjs/modules.js +2 -1
- package/lib/commonjs/specs/MedicationModule.nitro.js +27 -0
- package/lib/commonjs/types/Constants.js +2 -1
- package/lib/commonjs/types/QuantityType.js +8 -1
- package/lib/commonjs/types/QueryOptions.js +18 -0
- package/lib/commonjs/types/WeatherCondition.js +32 -32
- package/lib/commonjs/types/Workouts.js +1 -50
- package/lib/commonjs/utils/getCategorySampleById.js +1 -1
- package/lib/commonjs/utils/getQuantitySampleById.js +1 -1
- package/lib/commonjs/utils/getWorkoutById.js +1 -1
- package/lib/commonjs/utils/subscribeToCategorySamples.js +29 -0
- package/lib/commonjs/utils/subscribeToQuantitySamples.js +8 -25
- package/lib/module/healthkit.ios.js +20 -2
- package/lib/module/healthkit.js +32 -2
- package/lib/module/hooks/useStatisticsForQuantity.js +1 -1
- package/lib/module/hooks/useSubscribeToCategorySamples.js +17 -0
- package/lib/module/modules.js +1 -0
- package/lib/module/specs/MedicationModule.nitro.js +26 -0
- package/lib/module/types/Constants.js +1 -0
- package/lib/module/types/QuantityType.js +7 -0
- package/lib/module/types/QueryOptions.js +17 -1
- package/lib/module/types/WeatherCondition.js +31 -31
- package/lib/module/types/Workouts.js +0 -49
- package/lib/module/utils/getCategorySampleById.js +1 -1
- package/lib/module/utils/getQuantitySampleById.js +1 -1
- package/lib/module/utils/getWorkoutById.js +1 -1
- package/lib/module/utils/subscribeToCategorySamples.js +26 -0
- package/lib/module/utils/subscribeToQuantitySamples.js +8 -25
- package/lib/typescript/healthkit.d.ts +18 -9
- package/lib/typescript/healthkit.ios.d.ts +33 -15
- package/lib/typescript/hooks/useSubscribeToCategorySamples.d.ts +3 -0
- package/lib/typescript/modules.d.ts +2 -0
- package/lib/typescript/specs/CategoryTypeModule.nitro.d.ts +2 -2
- package/lib/typescript/specs/CoreModule.nitro.d.ts +2 -1
- package/lib/typescript/specs/CorrelationTypeModule.nitro.d.ts +4 -2
- package/lib/typescript/specs/ElectrocardiogramModule.nitro.d.ts +1 -1
- package/lib/typescript/specs/HeartbeatSeriesModule.nitro.d.ts +1 -1
- package/lib/typescript/specs/MedicationModule.nitro.d.ts +56 -0
- package/lib/typescript/specs/QuantityTypeModule.nitro.d.ts +4 -4
- package/lib/typescript/specs/StateOfMindModule.nitro.d.ts +4 -3
- package/lib/typescript/types/CategoryType.d.ts +10 -20
- package/lib/typescript/types/Constants.d.ts +1 -0
- package/lib/typescript/types/CorrelationType.d.ts +8 -10
- package/lib/typescript/types/ElectrocardiogramSample.d.ts +2 -12
- package/lib/typescript/types/HeartbeatSeries.d.ts +2 -14
- package/lib/typescript/types/QuantitySample.d.ts +2 -8
- package/lib/typescript/types/QuantityType.d.ts +7 -8
- package/lib/typescript/types/QuantityTypeIdentifier.d.ts +23 -23
- package/lib/typescript/types/QueryOptions.d.ts +43 -28
- package/lib/typescript/types/Shared.d.ts +52 -7
- package/lib/typescript/types/StateOfMind.d.ts +7 -10
- package/lib/typescript/types/Subscriptions.d.ts +12 -3
- package/lib/typescript/types/WeatherCondition.d.ts +1 -1
- package/lib/typescript/types/Workouts.d.ts +28 -81
- package/lib/typescript/utils/subscribeToCategorySamples.d.ts +5 -0
- package/nitrogen/generated/ios/ReactNativeHealthkit-Swift-Cxx-Bridge.cpp +57 -0
- package/nitrogen/generated/ios/ReactNativeHealthkit-Swift-Cxx-Bridge.hpp +592 -389
- package/nitrogen/generated/ios/ReactNativeHealthkit-Swift-Cxx-Umbrella.hpp +65 -30
- package/nitrogen/generated/ios/ReactNativeHealthkitAutolinking.mm +8 -0
- package/nitrogen/generated/ios/ReactNativeHealthkitAutolinking.swift +15 -0
- package/nitrogen/generated/ios/c++/HybridCategoryTypeModuleSpecSwift.hpp +32 -26
- package/nitrogen/generated/ios/c++/HybridCoreModuleSpecSwift.hpp +36 -37
- package/nitrogen/generated/ios/c++/HybridCorrelationTypeModuleSpecSwift.hpp +55 -2
- package/nitrogen/generated/ios/c++/HybridElectrocardiogramModuleSpecSwift.hpp +36 -30
- package/nitrogen/generated/ios/c++/HybridHeartbeatSeriesModuleSpecSwift.hpp +35 -29
- package/nitrogen/generated/ios/c++/HybridMedicationModuleSpecSwift.cpp +11 -0
- package/nitrogen/generated/ios/c++/HybridMedicationModuleSpecSwift.hpp +181 -0
- package/nitrogen/generated/ios/c++/HybridQuantityTypeModuleSpecSwift.hpp +48 -42
- package/nitrogen/generated/ios/c++/HybridStateOfMindModuleSpecSwift.hpp +59 -36
- package/nitrogen/generated/ios/c++/HybridWorkoutProxySpecSwift.hpp +150 -29
- package/nitrogen/generated/ios/c++/HybridWorkoutsModuleSpecSwift.hpp +13 -28
- package/nitrogen/generated/ios/swift/AggregationStyle.swift +48 -0
- package/nitrogen/generated/ios/swift/CategorySample.swift +571 -24
- package/nitrogen/generated/ios/swift/ComparisonPredicateOperator.swift +2 -2
- package/nitrogen/generated/ios/swift/CorrelationSample.swift +640 -17
- package/nitrogen/generated/ios/swift/{PredicateWithStartAndEnd.swift → DateFilter.swift} +5 -5
- package/nitrogen/generated/ios/swift/ECGQueryOptionsWithAnchor.swift +11 -91
- package/nitrogen/generated/ios/swift/ECGQueryOptionsWithSortOrder.swift +11 -91
- package/nitrogen/generated/ios/swift/ElectrocardiogramSample.swift +570 -72
- package/nitrogen/generated/ios/swift/FilterForSamples.swift +349 -12
- package/nitrogen/generated/ios/swift/FilterForSamplesBase.swift +234 -0
- package/nitrogen/generated/ios/swift/FilterForWorkouts.swift +366 -0
- package/nitrogen/generated/ios/swift/FilterForWorkoutsBase.swift +240 -0
- package/nitrogen/generated/ios/swift/Func_void_MedicationDoseEventsWithAnchorResponse.swift +47 -0
- package/nitrogen/generated/ios/swift/Func_void_QueryCorrelationSamplesWithAnchorResponse.swift +47 -0
- package/nitrogen/generated/ios/swift/Func_void_StateOfMindSamplesWithAnchorResponse.swift +47 -0
- package/nitrogen/generated/ios/swift/Func_void_std__vector_MedicationDoseEvent_.swift +47 -0
- package/nitrogen/generated/ios/swift/Func_void_std__vector_UserAnnotatedMedication_.swift +47 -0
- package/nitrogen/generated/ios/swift/GeneralForm.swift +104 -0
- package/nitrogen/generated/ios/swift/HeartRateMotionContext.swift +44 -0
- package/nitrogen/generated/ios/swift/HeartbeatSeriesSample.swift +565 -37
- package/nitrogen/generated/ios/swift/HybridCategoryTypeModuleSpec.swift +1 -1
- package/nitrogen/generated/ios/swift/HybridCategoryTypeModuleSpec_cxx.swift +2 -2
- package/nitrogen/generated/ios/swift/HybridCoreModuleSpec.swift +2 -1
- package/nitrogen/generated/ios/swift/HybridCoreModuleSpec_cxx.swift +19 -31
- package/nitrogen/generated/ios/swift/HybridCorrelationTypeModuleSpec.swift +2 -1
- package/nitrogen/generated/ios/swift/HybridCorrelationTypeModuleSpec_cxx.swift +21 -2
- package/nitrogen/generated/ios/swift/HybridElectrocardiogramModuleSpec.swift +1 -1
- package/nitrogen/generated/ios/swift/HybridElectrocardiogramModuleSpec_cxx.swift +2 -2
- package/nitrogen/generated/ios/swift/HybridHeartbeatSeriesModuleSpec.swift +1 -1
- package/nitrogen/generated/ios/swift/HybridHeartbeatSeriesModuleSpec_cxx.swift +2 -2
- package/nitrogen/generated/ios/swift/HybridMedicationModuleSpec.swift +60 -0
- package/nitrogen/generated/ios/swift/HybridMedicationModuleSpec_cxx.swift +208 -0
- package/nitrogen/generated/ios/swift/HybridQuantityTypeModuleSpec.swift +2 -2
- package/nitrogen/generated/ios/swift/HybridQuantityTypeModuleSpec_cxx.swift +9 -43
- package/nitrogen/generated/ios/swift/HybridStateOfMindModuleSpec.swift +2 -1
- package/nitrogen/generated/ios/swift/HybridStateOfMindModuleSpec_cxx.swift +21 -2
- package/nitrogen/generated/ios/swift/HybridWorkoutProxySpec.swift +34 -6
- package/nitrogen/generated/ios/swift/HybridWorkoutProxySpec_cxx.swift +376 -36
- package/nitrogen/generated/ios/swift/InsulinDeliveryReason.swift +40 -0
- package/nitrogen/generated/ios/swift/MedicationConcept.swift +80 -0
- package/nitrogen/generated/ios/swift/MedicationDoseEvent.swift +781 -0
- package/nitrogen/generated/ios/swift/MedicationDoseEventLogStatus.swift +56 -0
- package/nitrogen/generated/ios/swift/MedicationDoseEventScheduleType.swift +40 -0
- package/nitrogen/generated/ios/swift/MedicationDoseEventsWithAnchorResponse.swift +81 -0
- package/nitrogen/generated/ios/swift/ObjectTypeIdentifier.swift +16 -16
- package/nitrogen/generated/ios/swift/PredicateWithMetadataKey.swift +7 -7
- package/nitrogen/generated/ios/swift/QuantitySample.swift +574 -27
- package/nitrogen/generated/ios/swift/QuantityTypeIdentifier.swift +16 -16
- package/nitrogen/generated/ios/swift/QueryCorrelationSamplesWithAnchorResponse.swift +81 -0
- package/nitrogen/generated/ios/swift/QueryOptionsWithAnchor.swift +11 -91
- package/nitrogen/generated/ios/swift/QueryOptionsWithAnchorAndUnit.swift +11 -91
- package/nitrogen/generated/ios/swift/QueryOptionsWithSortOrder.swift +11 -91
- package/nitrogen/generated/ios/swift/QueryOptionsWithSortOrderAndUnit.swift +11 -91
- package/nitrogen/generated/ios/swift/RelatedCoding.swift +76 -0
- package/nitrogen/generated/ios/swift/SampleType.swift +68 -0
- package/nitrogen/generated/ios/swift/SampleTypeIdentifier.swift +16 -16
- package/nitrogen/generated/ios/swift/SampleTypeIdentifierWriteable.swift +0 -16
- package/nitrogen/generated/ios/swift/StateOfMindSample.swift +586 -58
- package/nitrogen/generated/ios/swift/StateOfMindSamplesWithAnchorResponse.swift +81 -0
- package/nitrogen/generated/ios/swift/StatisticsQueryOptions.swift +7 -75
- package/nitrogen/generated/ios/swift/UserAnnotatedMedication.swift +87 -0
- package/nitrogen/generated/ios/swift/WeatherCondition.swift +144 -0
- package/nitrogen/generated/ios/swift/WorkoutQueryOptions.swift +11 -105
- package/nitrogen/generated/ios/swift/WorkoutQueryOptionsWithAnchor.swift +11 -105
- package/nitrogen/generated/ios/swift/WorkoutSample.swift +751 -78
- package/nitrogen/generated/shared/c++/AggregationStyle.hpp +64 -0
- package/nitrogen/generated/shared/c++/CategorySample.hpp +126 -23
- package/nitrogen/generated/shared/c++/CorrelationSample.hpp +134 -12
- package/nitrogen/generated/shared/c++/{PredicateWithStartAndEnd.hpp → DateFilter.hpp} +10 -10
- package/nitrogen/generated/shared/c++/ECGQueryOptionsWithAnchor.hpp +12 -31
- package/nitrogen/generated/shared/c++/ECGQueryOptionsWithSortOrder.hpp +12 -31
- package/nitrogen/generated/shared/c++/ElectrocardiogramSample.hpp +135 -36
- package/nitrogen/generated/shared/c++/FilterForSamples.hpp +124 -0
- package/nitrogen/generated/shared/c++/FilterForSamplesBase.hpp +109 -0
- package/nitrogen/generated/shared/c++/FilterForWorkouts.hpp +131 -0
- package/nitrogen/generated/shared/c++/FilterForWorkoutsBase.hpp +116 -0
- package/nitrogen/generated/shared/c++/GeneralForm.hpp +140 -0
- package/nitrogen/generated/shared/c++/HeartRateMotionContext.hpp +67 -0
- package/nitrogen/generated/shared/c++/HeartbeatSeriesSample.hpp +131 -28
- package/nitrogen/generated/shared/c++/HybridCategoryTypeModuleSpec.hpp +1 -2
- package/nitrogen/generated/shared/c++/HybridCoreModuleSpec.cpp +1 -0
- package/nitrogen/generated/shared/c++/HybridCoreModuleSpec.hpp +10 -28
- package/nitrogen/generated/shared/c++/HybridCorrelationTypeModuleSpec.cpp +1 -0
- package/nitrogen/generated/shared/c++/HybridCorrelationTypeModuleSpec.hpp +11 -1
- package/nitrogen/generated/shared/c++/HybridElectrocardiogramModuleSpec.hpp +1 -2
- package/nitrogen/generated/shared/c++/HybridHeartbeatSeriesModuleSpec.hpp +1 -2
- package/nitrogen/generated/shared/c++/HybridMedicationModuleSpec.cpp +24 -0
- package/nitrogen/generated/shared/c++/HybridMedicationModuleSpec.hpp +80 -0
- package/nitrogen/generated/shared/c++/HybridQuantityTypeModuleSpec.cpp +1 -1
- package/nitrogen/generated/shared/c++/HybridQuantityTypeModuleSpec.hpp +6 -25
- package/nitrogen/generated/shared/c++/HybridStateOfMindModuleSpec.cpp +1 -0
- package/nitrogen/generated/shared/c++/HybridStateOfMindModuleSpec.hpp +9 -2
- package/nitrogen/generated/shared/c++/HybridWorkoutProxySpec.cpp +33 -5
- package/nitrogen/generated/shared/c++/HybridWorkoutProxySpec.hpp +56 -16
- package/nitrogen/generated/shared/c++/InsulinDeliveryReason.hpp +62 -0
- package/nitrogen/generated/shared/c++/MedicationConcept.hpp +93 -0
- package/nitrogen/generated/shared/c++/MedicationDoseEvent.hpp +240 -0
- package/nitrogen/generated/shared/c++/MedicationDoseEventLogStatus.hpp +66 -0
- package/nitrogen/generated/shared/c++/MedicationDoseEventScheduleType.hpp +62 -0
- package/nitrogen/generated/shared/c++/MedicationDoseEventsWithAnchorResponse.hpp +89 -0
- package/nitrogen/generated/shared/c++/ObjectTypeIdentifier.hpp +105 -105
- package/nitrogen/generated/shared/c++/PredicateWithMetadataKey.hpp +8 -8
- package/nitrogen/generated/shared/c++/QuantitySample.hpp +130 -27
- package/nitrogen/generated/shared/c++/QuantityTypeIdentifier.hpp +105 -105
- package/nitrogen/generated/shared/c++/QueryCorrelationSamplesWithAnchorResponse.hpp +89 -0
- package/nitrogen/generated/shared/c++/QueryOptionsWithAnchor.hpp +12 -31
- package/nitrogen/generated/shared/c++/QueryOptionsWithAnchorAndUnit.hpp +12 -31
- package/nitrogen/generated/shared/c++/QueryOptionsWithSortOrder.hpp +12 -31
- package/nitrogen/generated/shared/c++/QueryOptionsWithSortOrderAndUnit.hpp +12 -31
- package/nitrogen/generated/shared/c++/RelatedCoding.hpp +84 -0
- package/nitrogen/generated/shared/c++/SampleType.hpp +87 -0
- package/nitrogen/generated/shared/c++/SampleTypeIdentifier.hpp +105 -105
- package/nitrogen/generated/shared/c++/SampleTypeIdentifierWriteable.hpp +105 -121
- package/nitrogen/generated/shared/c++/StateOfMindSample.hpp +139 -36
- package/nitrogen/generated/shared/c++/StateOfMindSamplesWithAnchorResponse.hpp +89 -0
- package/nitrogen/generated/shared/c++/StatisticsQueryOptions.hpp +8 -27
- package/nitrogen/generated/shared/c++/UserAnnotatedMedication.hpp +90 -0
- package/nitrogen/generated/shared/c++/WeatherCondition.hpp +88 -0
- package/nitrogen/generated/shared/c++/WorkoutQueryOptions.hpp +12 -37
- package/nitrogen/generated/shared/c++/WorkoutQueryOptionsWithAnchor.hpp +12 -37
- package/nitrogen/generated/shared/c++/WorkoutSample.hpp +159 -35
- package/package.json +1 -1
- package/src/healthkit.ios.ts +30 -0
- package/src/healthkit.ts +68 -3
- package/src/hooks/useStatisticsForQuantity.ts +1 -1
- package/src/hooks/useSubscribeToCategorySamples.ts +31 -0
- package/src/modules.ts +4 -0
- package/src/specs/CategoryTypeModule.nitro.ts +2 -2
- package/src/specs/CoreModule.nitro.ts +3 -0
- package/src/specs/CorrelationTypeModule.nitro.ts +11 -3
- package/src/specs/ElectrocardiogramModule.nitro.ts +1 -1
- package/src/specs/HeartbeatSeriesModule.nitro.ts +1 -1
- package/src/specs/MedicationModule.nitro.ts +140 -0
- package/src/specs/QuantityTypeModule.nitro.ts +4 -7
- package/src/specs/StateOfMindModule.nitro.ts +10 -2
- package/src/types/CategoryType.ts +15 -22
- package/src/types/Constants.ts +3 -0
- package/src/types/CorrelationType.ts +10 -15
- package/src/types/ElectrocardiogramSample.ts +2 -14
- package/src/types/HeartbeatSeries.ts +2 -15
- package/src/types/QuantitySample.ts +2 -8
- package/src/types/QuantityType.ts +8 -17
- package/src/types/QuantityTypeIdentifier.ts +25 -25
- package/src/types/QueryOptions.ts +54 -43
- package/src/types/Shared.ts +74 -17
- package/src/types/StateOfMind.ts +8 -10
- package/src/types/Subscriptions.ts +19 -3
- package/src/types/WeatherCondition.ts +1 -1
- package/src/types/Workouts.ts +28 -91
- package/src/utils/getCategorySampleById.ts +1 -1
- package/src/utils/getQuantitySampleById.ts +1 -1
- package/src/utils/getWorkoutById.ts +1 -2
- package/src/utils/subscribeToCategorySamples.ts +38 -0
- package/src/utils/subscribeToQuantitySamples.ts +12 -37
- package/nitrogen/generated/ios/swift/FilterForSamplesAnd.swift +0 -94
- package/nitrogen/generated/ios/swift/FilterForSamplesOr.swift +0 -94
- package/nitrogen/generated/ios/swift/PredicateForSamples.swift +0 -21
- package/nitrogen/generated/ios/swift/PredicateForWorkouts.swift +0 -23
- package/nitrogen/generated/ios/swift/PredicateForWorkoutsAnd.swift +0 -108
- package/nitrogen/generated/ios/swift/PredicateForWorkoutsOr.swift +0 -108
- package/nitrogen/generated/ios/swift/PredicateFromWorkout.swift +0 -45
- package/nitrogen/generated/ios/swift/PredicateWithMetadataOperator.swift +0 -48
- package/nitrogen/generated/ios/swift/PredicateWithUUID.swift +0 -35
- package/nitrogen/generated/ios/swift/PredicateWithUUIDs.swift +0 -47
- package/nitrogen/generated/ios/swift/Variant_PredicateWithUUID_PredicateWithUUIDs_PredicateWithMetadataKey_PredicateWithStartAndEnd_PredicateFromWorkout_FilterForSamplesAnd_FilterForSamplesOr.swift +0 -23
- package/nitrogen/generated/ios/swift/Variant_PredicateWithUUID_PredicateWithUUIDs_PredicateWithMetadataKey_PredicateWithStartAndEnd_PredicateFromWorkout_WorkoutActivityTypePredicate_WorkoutDurationPredicate_PredicateForWorkoutsOr_PredicateForWorkoutsAnd.swift +0 -25
- package/nitrogen/generated/ios/swift/WorkoutActivityTypePredicate.swift +0 -35
- package/nitrogen/generated/shared/c++/FilterForSamplesAnd.hpp +0 -90
- package/nitrogen/generated/shared/c++/FilterForSamplesOr.hpp +0 -90
- package/nitrogen/generated/shared/c++/PredicateForWorkoutsAnd.hpp +0 -96
- package/nitrogen/generated/shared/c++/PredicateForWorkoutsOr.hpp +0 -96
- package/nitrogen/generated/shared/c++/PredicateFromWorkout.hpp +0 -77
- package/nitrogen/generated/shared/c++/PredicateWithMetadataOperator.hpp +0 -84
- package/nitrogen/generated/shared/c++/PredicateWithUUID.hpp +0 -75
- package/nitrogen/generated/shared/c++/PredicateWithUUIDs.hpp +0 -76
- package/nitrogen/generated/shared/c++/WorkoutActivityTypePredicate.hpp +0 -76
|
@@ -115,6 +115,229 @@ open class HybridWorkoutProxySpec_cxx {
|
|
|
115
115
|
}
|
|
116
116
|
|
|
117
117
|
// Properties
|
|
118
|
+
public final var workoutActivityType: Int32 {
|
|
119
|
+
@inline(__always)
|
|
120
|
+
get {
|
|
121
|
+
return self.__implementation.workoutActivityType.rawValue
|
|
122
|
+
}
|
|
123
|
+
}
|
|
124
|
+
|
|
125
|
+
public final var duration: Quantity {
|
|
126
|
+
@inline(__always)
|
|
127
|
+
get {
|
|
128
|
+
return self.__implementation.duration
|
|
129
|
+
}
|
|
130
|
+
}
|
|
131
|
+
|
|
132
|
+
public final var events: bridge.std__optional_std__vector_WorkoutEvent__ {
|
|
133
|
+
@inline(__always)
|
|
134
|
+
get {
|
|
135
|
+
return { () -> bridge.std__optional_std__vector_WorkoutEvent__ in
|
|
136
|
+
if let __unwrappedValue = self.__implementation.events {
|
|
137
|
+
return bridge.create_std__optional_std__vector_WorkoutEvent__({ () -> bridge.std__vector_WorkoutEvent_ in
|
|
138
|
+
var __vector = bridge.create_std__vector_WorkoutEvent_(__unwrappedValue.count)
|
|
139
|
+
for __item in __unwrappedValue {
|
|
140
|
+
__vector.push_back(__item)
|
|
141
|
+
}
|
|
142
|
+
return __vector
|
|
143
|
+
}())
|
|
144
|
+
} else {
|
|
145
|
+
return .init()
|
|
146
|
+
}
|
|
147
|
+
}()
|
|
148
|
+
}
|
|
149
|
+
}
|
|
150
|
+
|
|
151
|
+
public final var activities: bridge.std__optional_std__vector_WorkoutActivity__ {
|
|
152
|
+
@inline(__always)
|
|
153
|
+
get {
|
|
154
|
+
return { () -> bridge.std__optional_std__vector_WorkoutActivity__ in
|
|
155
|
+
if let __unwrappedValue = self.__implementation.activities {
|
|
156
|
+
return bridge.create_std__optional_std__vector_WorkoutActivity__({ () -> bridge.std__vector_WorkoutActivity_ in
|
|
157
|
+
var __vector = bridge.create_std__vector_WorkoutActivity_(__unwrappedValue.count)
|
|
158
|
+
for __item in __unwrappedValue {
|
|
159
|
+
__vector.push_back(__item)
|
|
160
|
+
}
|
|
161
|
+
return __vector
|
|
162
|
+
}())
|
|
163
|
+
} else {
|
|
164
|
+
return .init()
|
|
165
|
+
}
|
|
166
|
+
}()
|
|
167
|
+
}
|
|
168
|
+
}
|
|
169
|
+
|
|
170
|
+
public final var metadataAverageMETs: bridge.std__optional_Quantity_ {
|
|
171
|
+
@inline(__always)
|
|
172
|
+
get {
|
|
173
|
+
return { () -> bridge.std__optional_Quantity_ in
|
|
174
|
+
if let __unwrappedValue = self.__implementation.metadataAverageMETs {
|
|
175
|
+
return bridge.create_std__optional_Quantity_(__unwrappedValue)
|
|
176
|
+
} else {
|
|
177
|
+
return .init()
|
|
178
|
+
}
|
|
179
|
+
}()
|
|
180
|
+
}
|
|
181
|
+
}
|
|
182
|
+
|
|
183
|
+
public final var metadataElevationAscended: bridge.std__optional_Quantity_ {
|
|
184
|
+
@inline(__always)
|
|
185
|
+
get {
|
|
186
|
+
return { () -> bridge.std__optional_Quantity_ in
|
|
187
|
+
if let __unwrappedValue = self.__implementation.metadataElevationAscended {
|
|
188
|
+
return bridge.create_std__optional_Quantity_(__unwrappedValue)
|
|
189
|
+
} else {
|
|
190
|
+
return .init()
|
|
191
|
+
}
|
|
192
|
+
}()
|
|
193
|
+
}
|
|
194
|
+
}
|
|
195
|
+
|
|
196
|
+
public final var metadataElevationDescended: bridge.std__optional_Quantity_ {
|
|
197
|
+
@inline(__always)
|
|
198
|
+
get {
|
|
199
|
+
return { () -> bridge.std__optional_Quantity_ in
|
|
200
|
+
if let __unwrappedValue = self.__implementation.metadataElevationDescended {
|
|
201
|
+
return bridge.create_std__optional_Quantity_(__unwrappedValue)
|
|
202
|
+
} else {
|
|
203
|
+
return .init()
|
|
204
|
+
}
|
|
205
|
+
}()
|
|
206
|
+
}
|
|
207
|
+
}
|
|
208
|
+
|
|
209
|
+
public final var metadataIndoorWorkout: bridge.std__optional_bool_ {
|
|
210
|
+
@inline(__always)
|
|
211
|
+
get {
|
|
212
|
+
return { () -> bridge.std__optional_bool_ in
|
|
213
|
+
if let __unwrappedValue = self.__implementation.metadataIndoorWorkout {
|
|
214
|
+
return bridge.create_std__optional_bool_(__unwrappedValue)
|
|
215
|
+
} else {
|
|
216
|
+
return .init()
|
|
217
|
+
}
|
|
218
|
+
}()
|
|
219
|
+
}
|
|
220
|
+
}
|
|
221
|
+
|
|
222
|
+
public final var metadataAverageSpeed: bridge.std__optional_Quantity_ {
|
|
223
|
+
@inline(__always)
|
|
224
|
+
get {
|
|
225
|
+
return { () -> bridge.std__optional_Quantity_ in
|
|
226
|
+
if let __unwrappedValue = self.__implementation.metadataAverageSpeed {
|
|
227
|
+
return bridge.create_std__optional_Quantity_(__unwrappedValue)
|
|
228
|
+
} else {
|
|
229
|
+
return .init()
|
|
230
|
+
}
|
|
231
|
+
}()
|
|
232
|
+
}
|
|
233
|
+
}
|
|
234
|
+
|
|
235
|
+
public final var metadataMaximumSpeed: bridge.std__optional_Quantity_ {
|
|
236
|
+
@inline(__always)
|
|
237
|
+
get {
|
|
238
|
+
return { () -> bridge.std__optional_Quantity_ in
|
|
239
|
+
if let __unwrappedValue = self.__implementation.metadataMaximumSpeed {
|
|
240
|
+
return bridge.create_std__optional_Quantity_(__unwrappedValue)
|
|
241
|
+
} else {
|
|
242
|
+
return .init()
|
|
243
|
+
}
|
|
244
|
+
}()
|
|
245
|
+
}
|
|
246
|
+
}
|
|
247
|
+
|
|
248
|
+
public final var sampleType: SampleType {
|
|
249
|
+
@inline(__always)
|
|
250
|
+
get {
|
|
251
|
+
return self.__implementation.sampleType
|
|
252
|
+
}
|
|
253
|
+
}
|
|
254
|
+
|
|
255
|
+
public final var startDate: margelo.nitro.chrono_time {
|
|
256
|
+
@inline(__always)
|
|
257
|
+
get {
|
|
258
|
+
return self.__implementation.startDate.toCpp()
|
|
259
|
+
}
|
|
260
|
+
}
|
|
261
|
+
|
|
262
|
+
public final var endDate: margelo.nitro.chrono_time {
|
|
263
|
+
@inline(__always)
|
|
264
|
+
get {
|
|
265
|
+
return self.__implementation.endDate.toCpp()
|
|
266
|
+
}
|
|
267
|
+
}
|
|
268
|
+
|
|
269
|
+
public final var hasUndeterminedDuration: Bool {
|
|
270
|
+
@inline(__always)
|
|
271
|
+
get {
|
|
272
|
+
return self.__implementation.hasUndeterminedDuration
|
|
273
|
+
}
|
|
274
|
+
}
|
|
275
|
+
|
|
276
|
+
public final var metadataWeatherCondition: bridge.std__optional_WeatherCondition_ {
|
|
277
|
+
@inline(__always)
|
|
278
|
+
get {
|
|
279
|
+
return { () -> bridge.std__optional_WeatherCondition_ in
|
|
280
|
+
if let __unwrappedValue = self.__implementation.metadataWeatherCondition {
|
|
281
|
+
return bridge.create_std__optional_WeatherCondition_(__unwrappedValue)
|
|
282
|
+
} else {
|
|
283
|
+
return .init()
|
|
284
|
+
}
|
|
285
|
+
}()
|
|
286
|
+
}
|
|
287
|
+
}
|
|
288
|
+
|
|
289
|
+
public final var metadataWeatherHumidity: bridge.std__optional_Quantity_ {
|
|
290
|
+
@inline(__always)
|
|
291
|
+
get {
|
|
292
|
+
return { () -> bridge.std__optional_Quantity_ in
|
|
293
|
+
if let __unwrappedValue = self.__implementation.metadataWeatherHumidity {
|
|
294
|
+
return bridge.create_std__optional_Quantity_(__unwrappedValue)
|
|
295
|
+
} else {
|
|
296
|
+
return .init()
|
|
297
|
+
}
|
|
298
|
+
}()
|
|
299
|
+
}
|
|
300
|
+
}
|
|
301
|
+
|
|
302
|
+
public final var metadataWeatherTemperature: bridge.std__optional_Quantity_ {
|
|
303
|
+
@inline(__always)
|
|
304
|
+
get {
|
|
305
|
+
return { () -> bridge.std__optional_Quantity_ in
|
|
306
|
+
if let __unwrappedValue = self.__implementation.metadataWeatherTemperature {
|
|
307
|
+
return bridge.create_std__optional_Quantity_(__unwrappedValue)
|
|
308
|
+
} else {
|
|
309
|
+
return .init()
|
|
310
|
+
}
|
|
311
|
+
}()
|
|
312
|
+
}
|
|
313
|
+
}
|
|
314
|
+
|
|
315
|
+
public final var metadataInsulinDeliveryReason: bridge.std__optional_InsulinDeliveryReason_ {
|
|
316
|
+
@inline(__always)
|
|
317
|
+
get {
|
|
318
|
+
return { () -> bridge.std__optional_InsulinDeliveryReason_ in
|
|
319
|
+
if let __unwrappedValue = self.__implementation.metadataInsulinDeliveryReason {
|
|
320
|
+
return bridge.create_std__optional_InsulinDeliveryReason_(__unwrappedValue)
|
|
321
|
+
} else {
|
|
322
|
+
return .init()
|
|
323
|
+
}
|
|
324
|
+
}()
|
|
325
|
+
}
|
|
326
|
+
}
|
|
327
|
+
|
|
328
|
+
public final var metadataHeartRateMotionContext: bridge.std__optional_HeartRateMotionContext_ {
|
|
329
|
+
@inline(__always)
|
|
330
|
+
get {
|
|
331
|
+
return { () -> bridge.std__optional_HeartRateMotionContext_ in
|
|
332
|
+
if let __unwrappedValue = self.__implementation.metadataHeartRateMotionContext {
|
|
333
|
+
return bridge.create_std__optional_HeartRateMotionContext_(__unwrappedValue)
|
|
334
|
+
} else {
|
|
335
|
+
return .init()
|
|
336
|
+
}
|
|
337
|
+
}()
|
|
338
|
+
}
|
|
339
|
+
}
|
|
340
|
+
|
|
118
341
|
public final var uuid: std.string {
|
|
119
342
|
@inline(__always)
|
|
120
343
|
get {
|
|
@@ -122,6 +345,13 @@ open class HybridWorkoutProxySpec_cxx {
|
|
|
122
345
|
}
|
|
123
346
|
}
|
|
124
347
|
|
|
348
|
+
public final var sourceRevision: SourceRevision {
|
|
349
|
+
@inline(__always)
|
|
350
|
+
get {
|
|
351
|
+
return self.__implementation.sourceRevision
|
|
352
|
+
}
|
|
353
|
+
}
|
|
354
|
+
|
|
125
355
|
public final var device: bridge.std__optional_Device_ {
|
|
126
356
|
@inline(__always)
|
|
127
357
|
get {
|
|
@@ -135,40 +365,58 @@ open class HybridWorkoutProxySpec_cxx {
|
|
|
135
365
|
}
|
|
136
366
|
}
|
|
137
367
|
|
|
138
|
-
public final var
|
|
368
|
+
public final var metadata: margelo.nitro.SharedAnyMap {
|
|
139
369
|
@inline(__always)
|
|
140
370
|
get {
|
|
141
|
-
return self.__implementation.
|
|
371
|
+
return self.__implementation.metadata.cppPart
|
|
142
372
|
}
|
|
143
373
|
}
|
|
144
374
|
|
|
145
|
-
public final var
|
|
375
|
+
public final var metadataExternalUUID: bridge.std__optional_std__string_ {
|
|
146
376
|
@inline(__always)
|
|
147
377
|
get {
|
|
148
|
-
return
|
|
378
|
+
return { () -> bridge.std__optional_std__string_ in
|
|
379
|
+
if let __unwrappedValue = self.__implementation.metadataExternalUUID {
|
|
380
|
+
return bridge.create_std__optional_std__string_(std.string(__unwrappedValue))
|
|
381
|
+
} else {
|
|
382
|
+
return .init()
|
|
383
|
+
}
|
|
384
|
+
}()
|
|
149
385
|
}
|
|
150
386
|
}
|
|
151
387
|
|
|
152
|
-
public final var
|
|
388
|
+
public final var metadataTimeZone: bridge.std__optional_std__string_ {
|
|
153
389
|
@inline(__always)
|
|
154
390
|
get {
|
|
155
|
-
return
|
|
391
|
+
return { () -> bridge.std__optional_std__string_ in
|
|
392
|
+
if let __unwrappedValue = self.__implementation.metadataTimeZone {
|
|
393
|
+
return bridge.create_std__optional_std__string_(std.string(__unwrappedValue))
|
|
394
|
+
} else {
|
|
395
|
+
return .init()
|
|
396
|
+
}
|
|
397
|
+
}()
|
|
156
398
|
}
|
|
157
399
|
}
|
|
158
400
|
|
|
159
|
-
public final var
|
|
401
|
+
public final var metadataWasUserEntered: bridge.std__optional_bool_ {
|
|
160
402
|
@inline(__always)
|
|
161
403
|
get {
|
|
162
|
-
return
|
|
404
|
+
return { () -> bridge.std__optional_bool_ in
|
|
405
|
+
if let __unwrappedValue = self.__implementation.metadataWasUserEntered {
|
|
406
|
+
return bridge.create_std__optional_bool_(__unwrappedValue)
|
|
407
|
+
} else {
|
|
408
|
+
return .init()
|
|
409
|
+
}
|
|
410
|
+
}()
|
|
163
411
|
}
|
|
164
412
|
}
|
|
165
413
|
|
|
166
|
-
public final var
|
|
414
|
+
public final var metadataDeviceSerialNumber: bridge.std__optional_std__string_ {
|
|
167
415
|
@inline(__always)
|
|
168
416
|
get {
|
|
169
|
-
return { () -> bridge.
|
|
170
|
-
if let __unwrappedValue = self.__implementation.
|
|
171
|
-
return bridge.
|
|
417
|
+
return { () -> bridge.std__optional_std__string_ in
|
|
418
|
+
if let __unwrappedValue = self.__implementation.metadataDeviceSerialNumber {
|
|
419
|
+
return bridge.create_std__optional_std__string_(std.string(__unwrappedValue))
|
|
172
420
|
} else {
|
|
173
421
|
return .init()
|
|
174
422
|
}
|
|
@@ -176,12 +424,12 @@ open class HybridWorkoutProxySpec_cxx {
|
|
|
176
424
|
}
|
|
177
425
|
}
|
|
178
426
|
|
|
179
|
-
public final var
|
|
427
|
+
public final var metadataUdiDeviceIdentifier: bridge.std__optional_std__string_ {
|
|
180
428
|
@inline(__always)
|
|
181
429
|
get {
|
|
182
|
-
return { () -> bridge.
|
|
183
|
-
if let __unwrappedValue = self.__implementation.
|
|
184
|
-
return bridge.
|
|
430
|
+
return { () -> bridge.std__optional_std__string_ in
|
|
431
|
+
if let __unwrappedValue = self.__implementation.metadataUdiDeviceIdentifier {
|
|
432
|
+
return bridge.create_std__optional_std__string_(std.string(__unwrappedValue))
|
|
185
433
|
} else {
|
|
186
434
|
return .init()
|
|
187
435
|
}
|
|
@@ -189,18 +437,12 @@ open class HybridWorkoutProxySpec_cxx {
|
|
|
189
437
|
}
|
|
190
438
|
}
|
|
191
439
|
|
|
192
|
-
public final var
|
|
440
|
+
public final var metadataUdiProductionIdentifier: bridge.std__optional_std__string_ {
|
|
193
441
|
@inline(__always)
|
|
194
442
|
get {
|
|
195
|
-
return { () -> bridge.
|
|
196
|
-
if let __unwrappedValue = self.__implementation.
|
|
197
|
-
return bridge.
|
|
198
|
-
var __vector = bridge.create_std__vector_WorkoutEvent_(__unwrappedValue.count)
|
|
199
|
-
for __item in __unwrappedValue {
|
|
200
|
-
__vector.push_back(__item)
|
|
201
|
-
}
|
|
202
|
-
return __vector
|
|
203
|
-
}())
|
|
443
|
+
return { () -> bridge.std__optional_std__string_ in
|
|
444
|
+
if let __unwrappedValue = self.__implementation.metadataUdiProductionIdentifier {
|
|
445
|
+
return bridge.create_std__optional_std__string_(std.string(__unwrappedValue))
|
|
204
446
|
} else {
|
|
205
447
|
return .init()
|
|
206
448
|
}
|
|
@@ -208,18 +450,116 @@ open class HybridWorkoutProxySpec_cxx {
|
|
|
208
450
|
}
|
|
209
451
|
}
|
|
210
452
|
|
|
211
|
-
public final var
|
|
453
|
+
public final var metadataDigitalSignature: bridge.std__optional_std__string_ {
|
|
212
454
|
@inline(__always)
|
|
213
455
|
get {
|
|
214
|
-
return { () -> bridge.
|
|
215
|
-
if let __unwrappedValue = self.__implementation.
|
|
216
|
-
return bridge.
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
456
|
+
return { () -> bridge.std__optional_std__string_ in
|
|
457
|
+
if let __unwrappedValue = self.__implementation.metadataDigitalSignature {
|
|
458
|
+
return bridge.create_std__optional_std__string_(std.string(__unwrappedValue))
|
|
459
|
+
} else {
|
|
460
|
+
return .init()
|
|
461
|
+
}
|
|
462
|
+
}()
|
|
463
|
+
}
|
|
464
|
+
}
|
|
465
|
+
|
|
466
|
+
public final var metadataDeviceName: bridge.std__optional_std__string_ {
|
|
467
|
+
@inline(__always)
|
|
468
|
+
get {
|
|
469
|
+
return { () -> bridge.std__optional_std__string_ in
|
|
470
|
+
if let __unwrappedValue = self.__implementation.metadataDeviceName {
|
|
471
|
+
return bridge.create_std__optional_std__string_(std.string(__unwrappedValue))
|
|
472
|
+
} else {
|
|
473
|
+
return .init()
|
|
474
|
+
}
|
|
475
|
+
}()
|
|
476
|
+
}
|
|
477
|
+
}
|
|
478
|
+
|
|
479
|
+
public final var metadataDeviceManufacturerName: bridge.std__optional_std__string_ {
|
|
480
|
+
@inline(__always)
|
|
481
|
+
get {
|
|
482
|
+
return { () -> bridge.std__optional_std__string_ in
|
|
483
|
+
if let __unwrappedValue = self.__implementation.metadataDeviceManufacturerName {
|
|
484
|
+
return bridge.create_std__optional_std__string_(std.string(__unwrappedValue))
|
|
485
|
+
} else {
|
|
486
|
+
return .init()
|
|
487
|
+
}
|
|
488
|
+
}()
|
|
489
|
+
}
|
|
490
|
+
}
|
|
491
|
+
|
|
492
|
+
public final var metadataSyncIdentifier: bridge.std__optional_std__string_ {
|
|
493
|
+
@inline(__always)
|
|
494
|
+
get {
|
|
495
|
+
return { () -> bridge.std__optional_std__string_ in
|
|
496
|
+
if let __unwrappedValue = self.__implementation.metadataSyncIdentifier {
|
|
497
|
+
return bridge.create_std__optional_std__string_(std.string(__unwrappedValue))
|
|
498
|
+
} else {
|
|
499
|
+
return .init()
|
|
500
|
+
}
|
|
501
|
+
}()
|
|
502
|
+
}
|
|
503
|
+
}
|
|
504
|
+
|
|
505
|
+
public final var metadataSyncVersion: bridge.std__optional_double_ {
|
|
506
|
+
@inline(__always)
|
|
507
|
+
get {
|
|
508
|
+
return { () -> bridge.std__optional_double_ in
|
|
509
|
+
if let __unwrappedValue = self.__implementation.metadataSyncVersion {
|
|
510
|
+
return bridge.create_std__optional_double_(__unwrappedValue)
|
|
511
|
+
} else {
|
|
512
|
+
return .init()
|
|
513
|
+
}
|
|
514
|
+
}()
|
|
515
|
+
}
|
|
516
|
+
}
|
|
517
|
+
|
|
518
|
+
public final var metadataWasTakenInLab: bridge.std__optional_bool_ {
|
|
519
|
+
@inline(__always)
|
|
520
|
+
get {
|
|
521
|
+
return { () -> bridge.std__optional_bool_ in
|
|
522
|
+
if let __unwrappedValue = self.__implementation.metadataWasTakenInLab {
|
|
523
|
+
return bridge.create_std__optional_bool_(__unwrappedValue)
|
|
524
|
+
} else {
|
|
525
|
+
return .init()
|
|
526
|
+
}
|
|
527
|
+
}()
|
|
528
|
+
}
|
|
529
|
+
}
|
|
530
|
+
|
|
531
|
+
public final var metadataReferenceRangeLowerLimit: bridge.std__optional_double_ {
|
|
532
|
+
@inline(__always)
|
|
533
|
+
get {
|
|
534
|
+
return { () -> bridge.std__optional_double_ in
|
|
535
|
+
if let __unwrappedValue = self.__implementation.metadataReferenceRangeLowerLimit {
|
|
536
|
+
return bridge.create_std__optional_double_(__unwrappedValue)
|
|
537
|
+
} else {
|
|
538
|
+
return .init()
|
|
539
|
+
}
|
|
540
|
+
}()
|
|
541
|
+
}
|
|
542
|
+
}
|
|
543
|
+
|
|
544
|
+
public final var metadataReferenceRangeUpperLimit: bridge.std__optional_double_ {
|
|
545
|
+
@inline(__always)
|
|
546
|
+
get {
|
|
547
|
+
return { () -> bridge.std__optional_double_ in
|
|
548
|
+
if let __unwrappedValue = self.__implementation.metadataReferenceRangeUpperLimit {
|
|
549
|
+
return bridge.create_std__optional_double_(__unwrappedValue)
|
|
550
|
+
} else {
|
|
551
|
+
return .init()
|
|
552
|
+
}
|
|
553
|
+
}()
|
|
554
|
+
}
|
|
555
|
+
}
|
|
556
|
+
|
|
557
|
+
public final var metadataAlgorithmVersion: bridge.std__optional_double_ {
|
|
558
|
+
@inline(__always)
|
|
559
|
+
get {
|
|
560
|
+
return { () -> bridge.std__optional_double_ in
|
|
561
|
+
if let __unwrappedValue = self.__implementation.metadataAlgorithmVersion {
|
|
562
|
+
return bridge.create_std__optional_double_(__unwrappedValue)
|
|
223
563
|
} else {
|
|
224
564
|
return .init()
|
|
225
565
|
}
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
///
|
|
2
|
+
/// InsulinDeliveryReason.swift
|
|
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
|
+
/**
|
|
9
|
+
* Represents the JS enum `InsulinDeliveryReason`, backed by a C++ enum.
|
|
10
|
+
*/
|
|
11
|
+
public typealias InsulinDeliveryReason = margelo.nitro.healthkit.InsulinDeliveryReason
|
|
12
|
+
|
|
13
|
+
public extension InsulinDeliveryReason {
|
|
14
|
+
/**
|
|
15
|
+
* Get a InsulinDeliveryReason for the given String value, or
|
|
16
|
+
* return `nil` if the given value was invalid/unknown.
|
|
17
|
+
*/
|
|
18
|
+
init?(fromString string: String) {
|
|
19
|
+
switch string {
|
|
20
|
+
case "basal":
|
|
21
|
+
self = .basal
|
|
22
|
+
case "bolus":
|
|
23
|
+
self = .bolus
|
|
24
|
+
default:
|
|
25
|
+
return nil
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
/**
|
|
30
|
+
* Get the String value this InsulinDeliveryReason represents.
|
|
31
|
+
*/
|
|
32
|
+
var stringValue: String {
|
|
33
|
+
switch self {
|
|
34
|
+
case .basal:
|
|
35
|
+
return "basal"
|
|
36
|
+
case .bolus:
|
|
37
|
+
return "bolus"
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
}
|
|
@@ -0,0 +1,80 @@
|
|
|
1
|
+
///
|
|
2
|
+
/// MedicationConcept.swift
|
|
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
|
+
import NitroModules
|
|
9
|
+
|
|
10
|
+
/**
|
|
11
|
+
* Represents an instance of `MedicationConcept`, backed by a C++ struct.
|
|
12
|
+
*/
|
|
13
|
+
public typealias MedicationConcept = margelo.nitro.healthkit.MedicationConcept
|
|
14
|
+
|
|
15
|
+
public extension MedicationConcept {
|
|
16
|
+
private typealias bridge = margelo.nitro.healthkit.bridge.swift
|
|
17
|
+
|
|
18
|
+
/**
|
|
19
|
+
* Create a new instance of `MedicationConcept`.
|
|
20
|
+
*/
|
|
21
|
+
init(identifier: String, displayText: String, generalForm: GeneralForm, relatedCodings: [RelatedCoding]) {
|
|
22
|
+
self.init(std.string(identifier), std.string(displayText), generalForm, { () -> bridge.std__vector_RelatedCoding_ in
|
|
23
|
+
var __vector = bridge.create_std__vector_RelatedCoding_(relatedCodings.count)
|
|
24
|
+
for __item in relatedCodings {
|
|
25
|
+
__vector.push_back(__item)
|
|
26
|
+
}
|
|
27
|
+
return __vector
|
|
28
|
+
}())
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
var identifier: String {
|
|
32
|
+
@inline(__always)
|
|
33
|
+
get {
|
|
34
|
+
return String(self.__identifier)
|
|
35
|
+
}
|
|
36
|
+
@inline(__always)
|
|
37
|
+
set {
|
|
38
|
+
self.__identifier = std.string(newValue)
|
|
39
|
+
}
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
var displayText: String {
|
|
43
|
+
@inline(__always)
|
|
44
|
+
get {
|
|
45
|
+
return String(self.__displayText)
|
|
46
|
+
}
|
|
47
|
+
@inline(__always)
|
|
48
|
+
set {
|
|
49
|
+
self.__displayText = std.string(newValue)
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
var generalForm: GeneralForm {
|
|
54
|
+
@inline(__always)
|
|
55
|
+
get {
|
|
56
|
+
return self.__generalForm
|
|
57
|
+
}
|
|
58
|
+
@inline(__always)
|
|
59
|
+
set {
|
|
60
|
+
self.__generalForm = newValue
|
|
61
|
+
}
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
var relatedCodings: [RelatedCoding] {
|
|
65
|
+
@inline(__always)
|
|
66
|
+
get {
|
|
67
|
+
return self.__relatedCodings.map({ __item in __item })
|
|
68
|
+
}
|
|
69
|
+
@inline(__always)
|
|
70
|
+
set {
|
|
71
|
+
self.__relatedCodings = { () -> bridge.std__vector_RelatedCoding_ in
|
|
72
|
+
var __vector = bridge.create_std__vector_RelatedCoding_(newValue.count)
|
|
73
|
+
for __item in newValue {
|
|
74
|
+
__vector.push_back(__item)
|
|
75
|
+
}
|
|
76
|
+
return __vector
|
|
77
|
+
}()
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
}
|