public class TransferTable extends Object implements Serializable
StopTransfer, SpecificTransfer,
Serialized Form| Modifier and Type | Class and Description |
|---|---|
static class |
TransferTable.Transfer
Deprecated.
|
| Modifier and Type | Field and Description |
|---|---|
protected boolean |
preferredTransfers
Preferred transfers (or timed transfers, which are preferred as well) are present if true
|
protected HashMap<P2<org.onebusaway.gtfs.model.AgencyAndId>,StopTransfer> |
table
Table which contains transfers between two stops
|
| Constructor and Description |
|---|
TransferTable() |
| Modifier and Type | Method and Description |
|---|---|
void |
addTransferTime(org.onebusaway.gtfs.model.Stop fromStop,
org.onebusaway.gtfs.model.Stop toStop,
org.onebusaway.gtfs.model.Route fromRoute,
org.onebusaway.gtfs.model.Route toRoute,
org.onebusaway.gtfs.model.Trip fromTrip,
org.onebusaway.gtfs.model.Trip toTrip,
int transferTime)
Add a transfer time to the transfer table.
|
int |
determineTransferPenalty(int transferTime,
int nonpreferredTransferPenalty)
Determines the transfer penalty given a transfer time and a penalty for non-preferred
transfers.
|
Iterable<TransferTable.Transfer> |
getAllFirstSpecificTransfers()
Deprecated.
|
int |
getTransferTime(org.onebusaway.gtfs.model.Stop fromStop,
org.onebusaway.gtfs.model.Stop toStop,
org.onebusaway.gtfs.model.Trip fromTrip,
org.onebusaway.gtfs.model.Trip toTrip,
boolean forwardInTime)
Get the transfer time that should be used when transferring from a trip to another trip.
|
boolean |
hasPreferredTransfers() |
protected HashMap<P2<org.onebusaway.gtfs.model.AgencyAndId>,StopTransfer> table
protected boolean preferredTransfers
public boolean hasPreferredTransfers()
public int getTransferTime(org.onebusaway.gtfs.model.Stop fromStop,
org.onebusaway.gtfs.model.Stop toStop,
org.onebusaway.gtfs.model.Trip fromTrip,
org.onebusaway.gtfs.model.Trip toTrip,
boolean forwardInTime)
fromStop - is the arriving stoptoStop - is the departing stopfromTrip - is the arriving triptoTrip - is the departing tripforwardInTime - is true when moving forward in time; false when moving
backwards in time (usually this will be the variable "boarding")public void addTransferTime(org.onebusaway.gtfs.model.Stop fromStop,
org.onebusaway.gtfs.model.Stop toStop,
org.onebusaway.gtfs.model.Route fromRoute,
org.onebusaway.gtfs.model.Route toRoute,
org.onebusaway.gtfs.model.Trip fromTrip,
org.onebusaway.gtfs.model.Trip toTrip,
int transferTime)
fromStop - is the arriving stoptoStop - is the departing stopfromRoute - is the arriving route; is allowed to be nulltoRoute - is the departing route; is allowed to be nullfromTrip - is the arriving trip; is allowed to be nulltoTrip - is the departing trip; is allowed to be nulltransferTime - is the transfer time in seconds. May contain special (negative) values
which meaning can be found in the StopTransfer.*_TRANSFER constants. If no transfer is found,
StopTransfer.UNKNOWN_TRANSFER is returned.public int determineTransferPenalty(int transferTime,
int nonpreferredTransferPenalty)
transferTime - is the transfer timenonpreferredTransferPenalty - is the penalty for non-preferred transfers@Deprecated public Iterable<TransferTable.Transfer> getAllFirstSpecificTransfers()
TransferGraphLinkerCopyright © 2018. All rights reserved.