BusTripUpdate.fromPBEntity constructor
- FeedEntity entity
Implementation
BusTripUpdate.fromPBEntity(FeedEntity entity) {
id = entity.id;
isDeleted = entity.isDeleted;
tripId = entity.tripUpdate.trip.tripId;
startTime = entity.tripUpdate.trip.startTime;
startDate = entity.tripUpdate.trip.startDate;
routeId = entity.tripUpdate.trip.routeId;
entity.tripUpdate.stopTimeUpdate.forEach((entity) {
stopTimeUpdate.add(StopTimeUpdate.fromPBEntity(entity));
});
vehicleId = entity.tripUpdate.vehicle.id;
}