|
9 | 9 | import org.matsim.api.core.v01.events.handler.PersonStuckEventHandler;
|
10 | 10 | import org.matsim.api.core.v01.network.Link;
|
11 | 11 | import org.matsim.api.core.v01.network.Network;
|
12 |
| -import org.matsim.api.core.v01.population.Activity; |
13 |
| -import org.matsim.api.core.v01.population.Leg; |
14 |
| -import org.matsim.api.core.v01.population.Person; |
15 |
| -import org.matsim.api.core.v01.population.Plan; |
| 12 | +import org.matsim.api.core.v01.population.*; |
16 | 13 | import org.matsim.contrib.drt.passenger.AcceptedDrtRequest;
|
17 | 14 | import org.matsim.contrib.drt.prebooking.unscheduler.RequestUnscheduler;
|
18 | 15 | import org.matsim.contrib.dvrp.fleet.DvrpVehicle;
|
@@ -398,10 +395,9 @@ private void processRejections(double now) {
|
398 | 395 | if(abortRejectedPrebookings) {
|
399 | 396 | for (Id<Person> passengerId : item.request.getPassengerIds()) {
|
400 | 397 | MobsimAgent agent = internalInterface.getMobsim().getAgents().get(passengerId);
|
401 |
| - ((Activity) WithinDayAgentUtils.getCurrentPlanElement(agent)).setEndTime(Double.POSITIVE_INFINITY); |
402 |
| - ((Activity) WithinDayAgentUtils.getCurrentPlanElement(agent)).setMaximumDurationUndefined(); |
403 | 398 | ((HasModifiablePlan) agent).resetCaches();
|
404 |
| - internalInterface.getMobsim().rescheduleActivityEnd(agent); |
| 399 | + agent.setStateToAbort(mobsimTimer.getTimeOfDay()); |
| 400 | + internalInterface.arrangeNextAgentState(agent); |
405 | 401 | eventsManager.processEvent(new PersonStuckEvent(now, agent.getId(), agent.getCurrentLinkId(),
|
406 | 402 | this.mode));
|
407 | 403 | internalInterface.getMobsim().getAgentCounter().incLost();
|
|
0 commit comments