public class RaptorWorkerTimetable extends Object implements Serializable
Modifier and Type | Class and Description |
---|---|
static class |
RaptorWorkerTimetable.BoardingAssumption
The assumptions made when boarding a frequency vehicle: best case (no wait), worst case (full headway) and half headway (in some sense the average).
|
Modifier and Type | Field and Description |
---|---|
int |
dataIndex
Index of this pattern in RaptorData
|
static int |
MIN_BOARD_TIME_SECONDS
slack required when boarding a transit vehicle
|
int |
mode
Mode of this pattern, see constants in com.conveyal.gtfs.model.Route
|
RaptorWorkerData |
raptorData
parent raptorworkerdata of this timetable
|
String |
routeId
for debugging, the ID of the route this represents
|
int[] |
stopIndices
Indices of stops in parent data
|
int[][] |
timesPerTrip |
Constructor and Description |
---|
RaptorWorkerTimetable(int nTrips,
int nStops) |
Modifier and Type | Method and Description |
---|---|
int |
findDepartureAfter(int stop,
int time)
Return the trip index within the pattern of the soonest departure at the given stop number, requiring at least
MIN_BOARD_TIME_SECONDS seconds of slack.
|
static RaptorWorkerTimetable |
forAddedPattern(AddTripPattern atp,
TimeWindow window,
TaskStatistics ts)
Create a raptor worker timetable for an added pattern
|
static RaptorWorkerTimetable |
forPattern(Graph graph,
TripPattern pattern,
TimeWindow window,
Scenario scenario,
TaskStatistics ts)
This is a factory function rather than a constructor to avoid calling the super constructor for rejected patterns.
|
int |
getArrival(int trip,
int stop) |
int |
getDeparture(int trip,
int stop) |
int |
getFrequencyDeparture(int trip,
int stop,
int time,
int previousPattern,
FrequencyRandomOffsets offsets) |
int |
getFrequencyDeparture(int trip,
int stop,
int time,
int previousPattern,
FrequencyRandomOffsets offsets,
RaptorWorkerTimetable.BoardingAssumption assumption)
Get the departure on frequency trip trip at stop stop after time time,
with the given boarding assumption.
|
int |
getFrequencyTravelTime(int trip,
int from,
int to)
Get the travel time (departure to arrival) on frequency trip trip, from stop from to stop to.
|
int |
getFrequencyTripCount()
Get the number of frequency trips on this pattern (i.e.
|
boolean |
hasFrequencyTrips()
Does this timetable have any frequency trips?
|
boolean |
hasScheduledTrips()
does this timetable have any scheduled trips?
|
public int[][] timesPerTrip
public int[] stopIndices
public RaptorWorkerData raptorData
public int mode
public int dataIndex
public transient String routeId
public static final int MIN_BOARD_TIME_SECONDS
public int findDepartureAfter(int stop, int time)
public int getArrival(int trip, int stop)
public int getDeparture(int trip, int stop)
public int getFrequencyDeparture(int trip, int stop, int time, int previousPattern, FrequencyRandomOffsets offsets)
public int getFrequencyDeparture(int trip, int stop, int time, int previousPattern, FrequencyRandomOffsets offsets, RaptorWorkerTimetable.BoardingAssumption assumption)
public int getFrequencyTravelTime(int trip, int from, int to)
public int getFrequencyTripCount()
public boolean hasFrequencyTrips()
public boolean hasScheduledTrips()
public static RaptorWorkerTimetable forPattern(Graph graph, TripPattern pattern, TimeWindow window, Scenario scenario, TaskStatistics ts)
public static RaptorWorkerTimetable forAddedPattern(AddTripPattern atp, TimeWindow window, TaskStatistics ts)
Copyright © 2019. All rights reserved.