@Override
 public void handleEvent(TransitDriverStartsEvent event) {
   if (ptDrivers.contains(event.getDriverId())) {
     // already listed
   } else {
     ptDrivers.add(event.getDriverId());
     driverId2totalDistance.put(Id.createPersonId(event.getVehicleId()), 0.0);
   }
 }
 @Override
 public void handleEvent(final TransitDriverStartsEvent event) {
   if (this.calibratedLines.contains(event.getTransitLineId())) {
     this.analyzedTransitDrivers.add(event.getDriverId());
     this.analyzedTransitVehicles.add(event.getVehicleId());
   }
 }
 @Override
 public void handleEvent(TransitDriverStartsEvent event) {
   try {
     ptVehicles.put(
         event.getVehicleId(), new PTVehicle(event.getTransitLineId(), event.getTransitRouteId()));
     transitDriverIds.add(event.getDriverId());
   } catch (Exception e) {
     System.err.println(e.getStackTrace());
     System.err.println(event.toString());
     ;
   }
 }
예제 #4
0
 @Override
 public void handleEvent(TransitDriverStartsEvent event) {
   this.transitDrivers.add(event.getDriverId());
   this.transitVehicles.add(event.getVehicleId());
 }