You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: lib/models/workoutsummary.dart
+28-3Lines changed: 28 additions & 3 deletions
Original file line number
Diff line number
Diff line change
@@ -3,9 +3,9 @@ import 'dart:typed_data';
3
3
import'../helpers.dart';
4
4
import'types.dart';
5
5
6
-
/// Processes the raw byte data from workout summary characteristics into easily accessible fields
6
+
/// Represents a summary of a completed workout
7
7
///
8
-
/// This takes care of dealing with byte endianness, combining multiple high and low bytes .etc so that applications using the data only have to deal with flutter [int] types
8
+
/// This takes care of processesing the raw byte data from workout summary characteristics into easily accessible fields. This class also takes care of things like byte endianness, combining multiple high and low bytes .etc, allowing applications to access things in terms of flutter native types.
9
9
classWorkoutSummary {
10
10
finalDateTime timestamp;
11
11
finaldouble workTime;
@@ -19,7 +19,17 @@ class WorkoutSummary {
19
19
//recoveryHeartRate is sent as an amended packet later. zero is not valid
20
20
int? recoveryHeartRate;
21
21
finalWorkoutType workoutType;
22
+
finaldouble avgPace;
23
+
IntervalType? intervalType;
24
+
int? intervalSize;
25
+
int? intervalCount;
26
+
int? totalCalories;
27
+
int? watts;
28
+
int? totalRestDistance;
29
+
int? intervalRestTime;
30
+
int? avgCalories;
22
31
32
+
/// Construct a WorkoutSummary from the bytes returned from the erg
0 commit comments