public class FlagStopGraphModifier extends GtfsFlexGraphModifier
graph
Constructor and Description |
---|
FlagStopGraphModifier(Graph graph) |
Modifier and Type | Method and Description |
---|---|
boolean |
checkHopAllowsBoardAlight(State state,
FlexPatternHop hop,
boolean boarding)
Returns true if the given hop can be boarded/alighted.
|
StreetVertex |
getLocationForTemporaryStop(State s,
FlexPatternHop hop)
Subclasses can specify where the new temporary stop should be created, given a nearby
PatternHop.
|
TraverseMode |
getMode()
Return the mode that the graph search should be in.
|
SearchTerminationStrategy |
getSearchTerminationStrategy()
Return the termination strategy which should be used during the graph search.
|
TemporaryPartialPatternHop |
makeHopNewFrom(RoutingRequest opt,
State state,
FlexPatternHop hop,
PatternDepartVertex from,
Stop fromStop)
Create a new
FlexPatternHop with a new "from" location (from a new destination to the route). |
TemporaryPartialPatternHop |
makeHopNewTo(RoutingRequest opt,
State state,
FlexPatternHop hop,
PatternArriveVertex to,
Stop toStop)
Create a new
FlexPatternHop with a new "to" location (from the route to a new destination). |
TemporaryPartialPatternHop |
shortenEnd(RoutingRequest opt,
State state,
TemporaryPartialPatternHop hop,
PatternStopVertex to,
Stop toStop)
From an existing TemporaryPartialPatternHop which has a new "from" location, create a new
TemporaryPartialPatternHop with the same "from" location and a new "to" location.
|
createBackwardHops, createDirectHop, createForwardHops, getTemporaryStop, getTemporaryStop, streetSearch, vertexVisitor
public FlagStopGraphModifier(Graph graph)
public TraverseMode getMode()
GtfsFlexGraphModifier
getMode
in class GtfsFlexGraphModifier
public SearchTerminationStrategy getSearchTerminationStrategy()
GtfsFlexGraphModifier
getSearchTerminationStrategy
in class GtfsFlexGraphModifier
public TemporaryPartialPatternHop makeHopNewTo(RoutingRequest opt, State state, FlexPatternHop hop, PatternArriveVertex to, Stop toStop)
GtfsFlexGraphModifier
FlexPatternHop
with a new "to" location (from the route to a new destination).makeHopNewTo
in class GtfsFlexGraphModifier
opt
- Options for the graph searchstate
- State at which the original FlexPatternHop was found during the graph searchhop
- Original pattern hop to modifyto
- New "to" locationtoStop
- Stop for new "to" locationpublic TemporaryPartialPatternHop makeHopNewFrom(RoutingRequest opt, State state, FlexPatternHop hop, PatternDepartVertex from, Stop fromStop)
GtfsFlexGraphModifier
FlexPatternHop
with a new "from" location (from a new destination to the route).makeHopNewFrom
in class GtfsFlexGraphModifier
opt
- Options for the graph searchstate
- Options for the graph searchhop
- Original pattern hop to modifyfrom
- New "from" locationfromStop
- Stop for new "from" locationpublic TemporaryPartialPatternHop shortenEnd(RoutingRequest opt, State state, TemporaryPartialPatternHop hop, PatternStopVertex to, Stop toStop)
GtfsFlexGraphModifier
shortenEnd
in class GtfsFlexGraphModifier
opt
- Options for the graph searchstate
- ptions for the graph searchhop
- Temporary pattern hop to modifyto
- New "to" locationtoStop
- Stop for new "to" locationpublic StreetVertex getLocationForTemporaryStop(State s, FlexPatternHop hop)
GtfsFlexGraphModifier
getLocationForTemporaryStop
in class GtfsFlexGraphModifier
s
- State at which PatternHop was foundhop
- PatternHop found during graph searchpublic boolean checkHopAllowsBoardAlight(State state, FlexPatternHop hop, boolean boarding)
GtfsFlexGraphModifier
checkHopAllowsBoardAlight
in class GtfsFlexGraphModifier
Copyright © 2019. All rights reserved.