toJson method

Map<String, dynamic> toJson()

Returns a JSON representation of this ScheduleArrival.

Implementation

Map<String, dynamic> toJson() {
  return <String, dynamic>{
    ApiFields.directionNum: directionNum.toString(),
    ApiFields.endTime: endTime.toWmataString(),
    ApiFields.routeId: routeId,
    ApiFields.scheduleTime: scheduleTime.toWmataString(),
    ApiFields.startTime: startTime.toWmataString(),
    ApiFields.tripDirection: direction,
    ApiFields.tripHeadsign: tripHeadsign,
    ApiFields.tripId: tripId,
  };
}