org.opentripplanner.transit.raptor.rangeraptor.standard.StopArrivalsState Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of otp Show documentation
Show all versions of otp Show documentation
The OpenTripPlanner multimodal journey planning system
package org.opentripplanner.transit.raptor.rangeraptor.standard;
import org.opentripplanner.transit.raptor.api.path.Path;
import org.opentripplanner.transit.raptor.api.transit.RaptorTransfer;
import org.opentripplanner.transit.raptor.api.transit.RaptorTripSchedule;
import org.opentripplanner.transit.raptor.rangeraptor.standard.besttimes.BestTimes;
import java.util.Collection;
/**
* This interface define a superset of operations to maintain the stop arrivals state, and
* for the implementation to compute results. The Range Raptor algorithm do NOT depend on
* the state, only on the {@link BestTimes} - with one exception the {@link #bestTimePreviousRound(int)}.
*
* Different implementations may implement this to:
*
* - Compute paths
*
- Enable debugging
*
- Compute heuristics
*
*
* @param The TripSchedule type defined by the user of the raptor API.
*/
public interface StopArrivalsState {
void setAccess(final int stop, final int arrivalTime, RaptorTransfer access);
Collection> extractPaths();
int bestTimePreviousRound(int stop);
void setNewBestTransitTime(int alightStop, int alightTime, T trip, int boardStop, int boardTime, boolean newBestOverall);
void rejectNewBestTransitTime(int alightStop, int alightTime, T trip, int boardStop, int boardTime);
void setNewBestTransferTime(int fromStop, int arrivalTime, RaptorTransfer transferLeg);
void rejectNewBestTransferTime(int fromStop, int arrivalTime, RaptorTransfer transferLeg);
}