File tree Expand file tree Collapse file tree 5 files changed +8
-0
lines changed
oura-library/src/main/kotlin/org/radarbase/oura/converter Expand file tree Collapse file tree 5 files changed +8
-0
lines changed Original file line number Diff line number Diff line change @@ -38,6 +38,7 @@ class OuraHeartRateConverter(
3838 time = startTime.toEpochMilli() / 1000.0
3939 timeReceived = System .currentTimeMillis() / 1000.0
4040 source = data.get(" source" )?.textValue()?.classify()
41+ ? : OuraHeartRateSource .UNKNOWN
4142 bpm = data.get(" bpm" )?.intValue()
4243 }.build()
4344 }
Original file line number Diff line number Diff line change @@ -44,7 +44,9 @@ class OuraSessionConverter(
4444 timeReceived = System .currentTimeMillis() / 1000.0
4545 id = data.get(" id" )?.textValue()
4646 type = data.get(" type" )?.textValue()?.classifyType()
47+ ? : OuraMomentType .UNKNOWN
4748 mood = data.get(" mood" )?.textValue()?.classifyMood()
49+ ? : OuraMomentMood .UNKNOWN
4850 }.build()
4951 }
5052
Original file line number Diff line number Diff line change @@ -80,6 +80,7 @@ class OuraSleepConverter(
8080 timeInBed = data.get(" time_in_bed" )?.intValue()
8181 totalSleepDuration = data.get(" total_sleep_duration" )?.intValue()
8282 type = data.get(" type" )?.textValue()?.classifyType()
83+ ? : OuraSleepType .UNKNOWN
8384 }.build()
8485 }
8586
Original file line number Diff line number Diff line change @@ -49,7 +49,9 @@ class OuraSleepTimeRecommendationConverter(
4949 optimalBedtimeEndOffset = data.get(" optimal_bedtime" )?.get(" end_offset" )?.intValue()
5050 optimalBedtimeTimezoneOffset = data.get(" optimal_bedtime" )?.get(" day_tz" )?.intValue()
5151 recommendation = data.get(" recommendation" ).textValue()?.classifyRecommendation()
52+ ? : OuraSleepRecommendation .UNKNOWN
5253 status = data.get(" status" ).textValue()?.classifyStatus()
54+ ? : OuraSleepStatus .UNKNOWN
5355 }.build()
5456 }
5557
Original file line number Diff line number Diff line change @@ -48,8 +48,10 @@ class OuraWorkoutConverter(
4848 day = data.get(" day" )?.textValue()
4949 distance = data.get(" distance" )?.floatValue()
5050 intensity = data.get(" intensity" )?.textValue()?.classifyIntensity()
51+ ? : OuraWorkoutIntensity .UNKNOWN
5152 label = data.get(" label" )?.textValue()
5253 source = data.get(" source" )?.textValue()?.classifySource()
54+ ? : OuraWorkoutSource .UNKNOWN
5355 }.build()
5456 }
5557
You can’t perform that action at this time.
0 commit comments