toJson method

Map<String, dynamic> toJson()

Converts this object into JSON format.

Implementation

Map<String, dynamic> toJson() {
  return {
    ApiFields.direction: direction,
    ApiFields.steps: steps,
    ApiFields.duration: durationMilliseconds,
  };
}