PTCrowdingInfo constructor

PTCrowdingInfo({
  1. int? vehicles,
  2. PTCongestionLevel? congestionLevel,
  3. PTOccupancyStatus? occupancyStatus,
  4. int? occupancyPercentage,
})

Create a PTCrowdingInfo.

API users do not typically create instances of this class directly. Get instances from PTTrip.vehicle or PTRouteInfo.liveCrowding.

Parameters

  • vehicles: (int?) Number of fresh vehicle positions on the route.
  • congestionLevel: (PTCongestionLevel?) Congestion level of the traffic the vehicle(s) travel in.
  • occupancyStatus: (PTOccupancyStatus?) Occupancy status of the vehicle(s).
  • occupancyPercentage: (int?) Occupancy as a percentage of capacity.

Implementation

PTCrowdingInfo({
  this.vehicles,
  this.congestionLevel,
  this.occupancyStatus,
  this.occupancyPercentage,
});