Eclipse SUMO - Simulation of Urban MObility
|
#include <NBAlgorithms_Railway.h>
Data Structures | |
class | Track |
routing edge More... | |
Static Public Member Functions | |
static void | analyzeTopology (NBEdgeCont &ec) |
static void | extendDirectionPriority (NBEdgeCont &ec, bool fromUniDir) |
static std::set< NBNode * > | getRailNodes (NBEdgeCont &ec, bool verbose=false) |
static double | getTravelTimeStatic (const Track *const track, const NBVehicle *const veh, double time) |
static int | makeAllBidi (NBEdgeCont &ec) |
static int | repairTopology (NBEdgeCont &ec, NBPTStopCont &sc, NBPTLineCont &lc) |
Static Private Member Functions | |
static NBEdge * | addBidiEdge (NBEdgeCont &ec, NBEdge *edge, bool update=true) |
add bidi-edge for the given edge | |
static int | addBidiEdgesBetweenSwitches (NBEdgeCont &ec) |
add bidi-edges to connect switches that are approached in both directions | |
static int | addBidiEdgesForBufferStops (NBEdgeCont &ec) |
add bidi-edges to connect buffers stops in both directions | |
static int | addBidiEdgesForStops (NBEdgeCont &ec, NBPTLineCont &lc, NBPTStopCont &sc, bool minimal) |
add bidi-edges to connect successive public transport stops | |
static int | addBidiEdgesForStraightConnectivity (NBEdgeCont &ec, bool geometryLike) |
add bidi-edges to connect straight tracks | |
static bool | allBidi (const EdgeVector &edges) |
static bool | allBroken (const NBNode *node, NBEdge *candOut, const EdgeVector &in, const EdgeVector &out) |
static bool | allSharp (const NBNode *node, const EdgeVector &in, const EdgeVector &out, bool countBidiAsSharp=false) |
static int | extendBidiEdges (NBEdgeCont &ec) |
add further bidi-edges near existing bidi-edges | |
static int | extendBidiEdges (NBEdgeCont &ec, NBNode *node, NBEdge *bidiIn) |
static std::set< NBPTLine * > | findBidiCandidates (NBPTLineCont &lc) |
identify lines that are likely to require bidirectional tracks | |
static std::set< NBNode * > | getBrokenRailNodes (NBEdgeCont &ec, bool verbose=false) |
static void | getRailEdges (const NBNode *node, EdgeVector &inEdges, EdgeVector &outEdges) |
filter out rail edges among all edges of a the given node | |
static bool | hasRailway (SVCPermissions permissions) |
filter for rail edges but do not return (legacy) all purpose edges | |
static bool | hasStraightPair (const NBNode *node, const EdgeVector &edges, const EdgeVector &edges2) |
static NBEdge * | isBidiSwitch (const NBNode *n) |
static bool | isStraight (const NBNode *node, const NBEdge *e1, const NBEdge *e2) |
static int | reverseEdges (NBEdgeCont &ec, NBPTStopCont &sc) |
reverse edges sequences that are to broken nodes on both sides | |
static void | updateTurns (NBEdge *edge) |
recompute turning directions for both nodes of the given edge | |
Definition at line 49 of file NBAlgorithms_Railway.h.
|
staticprivate |
add bidi-edge for the given edge
Definition at line 180 of file NBAlgorithms_Railway.cpp.
References CENTER, NBEdge::getFromNode(), NBEdge::getGeometry(), NBEdge::getID(), NBNode::getIncomingEdges(), NBEdge::getLaneSpreadFunction(), Parameterised::getParameter(), NBEdge::getToNode(), hasRailway(), NBEdgeCont::insert(), NBEdge::isBidiRail(), NBTrafficLightDefinition::OSM_DIRECTION, NBEdgeCont::retrieve(), PositionVector::reverse(), Parameterised::setParameter(), TL, updateTurns(), NBEdgeCont::wasIgnored(), and WRITE_WARNINGF.
Referenced by addBidiEdgesBetweenSwitches(), addBidiEdgesForBufferStops(), addBidiEdgesForStops(), addBidiEdgesForStraightConnectivity(), extendBidiEdges(), and makeAllBidi().
|
staticprivate |
add bidi-edges to connect switches that are approached in both directions
Definition at line 778 of file NBAlgorithms_Railway.cpp.
References addBidiEdge(), CENTER, getBrokenRailNodes(), NBEdge::getFromNode(), NBEdge::getLaneSpreadFunction(), getRailEdges(), NBEdge::getToNode(), isBidiSwitch(), isStraight(), joinToString(), TL, toString(), and WRITE_MESSAGEF.
Referenced by repairTopology().
|
staticprivate |
add bidi-edges to connect buffers stops in both directions
Definition at line 684 of file NBAlgorithms_Railway.cpp.
References addBidiEdge(), CENTER, getBrokenRailNodes(), NBEdge::getFromNode(), getRailEdges(), getRailNodes(), NBEdge::getToNode(), NBEdge::setLaneSpreadFunction(), TL, StringUtils::toBool(), toString(), WRITE_MESSAGEF, and WRITE_WARNINGF.
Referenced by repairTopology().
|
staticprivate |
add bidi-edges to connect successive public transport stops
Definition at line 869 of file NBAlgorithms_Railway.cpp.
References addBidiEdge(), CENTER, SUMOAbstractRouter< E, V >::compute(), extendBidiEdges(), findBidiCandidates(), NBPTStopCont::get(), NBEdgeCont::getAllEdges(), OptionsCont::getFloat(), NBEdge::getID(), NBEdge::getLaneSpreadFunction(), NBPTLineCont::getLines(), OptionsCont::getOptions(), NBEdge::getPermissions(), getRailEdges(), getRailNodes(), NBPTLine::getRef(), NBPTStopCont::getReverseStop(), NBPTLine::getRouteEnd(), NBPTLine::getRouteStart(), NBPTLine::getStopEdges(), getTravelTimeStatic(), NBPTStopCont::insert(), NBEdge::isBidiRail(), NBPTLine::isConsistent(), isStraight(), SVC_RAIL_CLASSES, TL, toString(), WRITE_MESSAGE, and WRITE_WARNINGF.
Referenced by repairTopology().
|
staticprivate |
add bidi-edges to connect straight tracks
Definition at line 1080 of file NBAlgorithms_Railway.cpp.
References addBidiEdge(), extendBidiEdges(), getBrokenRailNodes(), getRailEdges(), hasRailway(), isStraight(), TL, toString(), and WRITE_MESSAGEF.
Referenced by repairTopology().
|
staticprivate |
Definition at line 503 of file NBAlgorithms_Railway.cpp.
Referenced by allSharp(), and getBrokenRailNodes().
|
staticprivate |
Definition at line 463 of file NBAlgorithms_Railway.cpp.
References gDebugFlag1, NBEdge::getID(), and isStraight().
Referenced by reverseEdges().
|
staticprivate |
Definition at line 485 of file NBAlgorithms_Railway.cpp.
References allBidi(), and isStraight().
Referenced by extendBidiEdges(), and getBrokenRailNodes().
|
static |
Definition at line 108 of file NBAlgorithms_Railway.cpp.
References getBrokenRailNodes().
Referenced by NBNetBuilder::compute().
|
staticprivate |
add further bidi-edges near existing bidi-edges
Definition at line 514 of file NBAlgorithms_Railway.cpp.
References NBEdgeCont::begin(), NBEdgeCont::end(), extendBidiEdges(), NBEdge::getFromNode(), NBEdge::getToNode(), NBEdge::getTurnDestination(), NBEdge::isBidiRail(), TL, toString(), and WRITE_MESSAGEF.
Referenced by addBidiEdgesForStops(), addBidiEdgesForStraightConnectivity(), extendBidiEdges(), extendBidiEdges(), and repairTopology().
|
staticprivate |
Definition at line 531 of file NBAlgorithms_Railway.cpp.
References addBidiEdge(), allSharp(), CENTER, extendBidiEdges(), NBEdge::getID(), getRailEdges(), NBEdge::getToNode(), NBEdge::getTurnDestination(), isStraight(), TL, and WRITE_WARNINGF.
|
static |
Definition at line 1178 of file NBAlgorithms_Railway.cpp.
References NBEdgeCont::getAllEdges(), NBEdge::getID(), Named::getIDSecure(), NBEdge::getPermissions(), NBEdge::getPriority(), NBEdge::getStraightContinuation(), NBEdge::getStraightPredecessor(), hasRailway(), joinToString(), NBEdge::setPriority(), TL, WRITE_MESSAGE, WRITE_WARNING, and WRITE_WARNINGF.
Referenced by NBNetBuilder::compute().
|
staticprivate |
identify lines that are likely to require bidirectional tracks
Definition at line 838 of file NBAlgorithms_Railway.cpp.
References NBPTLineCont::getLines().
Referenced by addBidiEdgesForStops().
|
staticprivate |
Definition at line 235 of file NBAlgorithms_Railway.cpp.
References allBidi(), allSharp(), OutputDevice::close(), OutputDevice::closeTag(), OutputDevice::getDevice(), NBEdge::getID(), OptionsCont::getOptions(), getRailEdges(), getRailNodes(), NBEdge::getTurnDestination(), hasStraightPair(), OutputDevice::openTag(), SUMO_ATTR_ID, SUMO_TAG_NODE, std::swap(), TL, StringUtils::toBool(), toString(), WRITE_MESSAGE, WRITE_MESSAGEF, OutputDevice::writeAttr(), and OutputDevice::writeXMLHeader().
Referenced by addBidiEdgesBetweenSwitches(), addBidiEdgesForBufferStops(), addBidiEdgesForStraightConnectivity(), analyzeTopology(), and reverseEdges().
|
staticprivate |
filter out rail edges among all edges of a the given node
Definition at line 219 of file NBAlgorithms_Railway.cpp.
References NBNode::getIncomingEdges(), NBNode::getOutgoingEdges(), and SVC_RAIL_CLASSES.
Referenced by addBidiEdgesBetweenSwitches(), addBidiEdgesForBufferStops(), addBidiEdgesForStops(), addBidiEdgesForStraightConnectivity(), extendBidiEdges(), getBrokenRailNodes(), isBidiSwitch(), and reverseEdges().
|
static |
Definition at line 390 of file NBAlgorithms_Railway.cpp.
References NBEdgeCont::begin(), NBEdgeCont::end(), hasRailway(), RAIL_SIGNAL, TL, toString(), and WRITE_MESSAGEF.
Referenced by addBidiEdgesForBufferStops(), addBidiEdgesForStops(), getBrokenRailNodes(), and NBRailwayGeometryHelper::straigthenCorrdidor().
|
static |
Definition at line 1172 of file NBAlgorithms_Railway.cpp.
References NBRailwayTopologyAnalyzer::Track::edge, NBEdge::getTravelTimeStatic(), and NBRailwayTopologyAnalyzer::Track::penalty.
Referenced by addBidiEdgesForStops().
|
inlinestaticprivate |
filter for rail edges but do not return (legacy) all purpose edges
Definition at line 117 of file NBAlgorithms_Railway.h.
References SVC_RAIL_CLASSES, and SVCAll.
Referenced by addBidiEdge(), addBidiEdgesForStraightConnectivity(), extendDirectionPriority(), getRailNodes(), and makeAllBidi().
|
staticprivate |
Definition at line 437 of file NBAlgorithms_Railway.cpp.
References isStraight().
Referenced by getBrokenRailNodes().
Definition at line 756 of file NBAlgorithms_Railway.cpp.
References getRailEdges(), and isStraight().
Referenced by addBidiEdgesBetweenSwitches().
|
staticprivate |
Definition at line 414 of file NBAlgorithms_Railway.cpp.
References NBEdge::getAngleAtNode(), NBEdge::getFromNode(), NBEdge::getToNode(), NBHelpers::normRelAngle(), SHARP_THRESHOLD, and SHARP_THRESHOLD_SAMEDIR.
Referenced by addBidiEdgesBetweenSwitches(), addBidiEdgesForStops(), addBidiEdgesForStraightConnectivity(), allBroken(), allSharp(), extendBidiEdges(), hasStraightPair(), and isBidiSwitch().
|
static |
Definition at line 136 of file NBAlgorithms_Railway.cpp.
References addBidiEdge(), CENTER, NBEdgeCont::getAllEdges(), OptionsCont::getOptions(), OptionsCont::getString(), hasRailway(), NBEdge::invalidateConnections(), NBHelpers::loadEdgesFromFile(), NBEdgeCont::retrieve(), TL, toString(), WRITE_MESSAGEF, and WRITE_WARNINGF.
Referenced by NBNetBuilder::compute().
|
static |
Definition at line 114 of file NBAlgorithms_Railway.cpp.
References addBidiEdgesBetweenSwitches(), addBidiEdgesForBufferStops(), addBidiEdgesForStops(), addBidiEdgesForStraightConnectivity(), extendBidiEdges(), OptionsCont::getBool(), NBPTLineCont::getLines(), OptionsCont::getOptions(), and reverseEdges().
Referenced by NBNetBuilder::compute().
|
staticprivate |
reverse edges sequences that are to broken nodes on both sides
Definition at line 572 of file NBAlgorithms_Railway.cpp.
References allBroken(), DEBUGNODEID, getBrokenRailNodes(), Named::getID(), getRailEdges(), NBPTStopCont::getStops(), joinToString(), NBTrafficLightDefinition::OSM_DIRECTION, Parameterised::setParameter(), TL, toString(), and WRITE_MESSAGEF.
Referenced by repairTopology().
|
staticprivate |
recompute turning directions for both nodes of the given edge
Definition at line 1165 of file NBAlgorithms_Railway.cpp.
References NBTurningDirectionsComputer::computeTurnDirectionsForNode(), NBEdge::getFromNode(), and NBEdge::getToNode().
Referenced by addBidiEdge().