SUMO - Simulation of Urban MObility
|
#include <MSRoute.h>
Public Member Functions | |
void | addParameter (const std::string &key, const std::string &value) |
Adds a parameter. More... | |
void | addParameter (const std::map< std::string, std::string > &mapArg) |
Adds all given parameter. More... | |
void | addParameter (const Parameterised &p) |
Adds all given parameter. More... | |
void | addReference () const |
increments the reference counter for the route More... | |
void | addTo (const StoringVisitor &cont) const |
Adds this object to the given container. More... | |
MSRouteIterator | begin () const |
Returns the begin of the list of edges to pass. More... | |
void | clearParameter () |
Clears the parameter map. More... | |
bool | contains (const MSEdge *const edge) const |
bool | containsAnyOf (const std::vector< MSEdge * > &edgelist) const |
MSRouteIterator | end () const |
Returns the end of the list of edges to pass. More... | |
const RGBColor & | getColor () const |
Returns the color. More... | |
SUMOReal | getDistanceBetween (SUMOReal fromPos, SUMOReal toPos, const MSEdge *fromEdge, const MSEdge *toEdge) const |
Compute the distance between 2 given edges on this route, including the length of internal lanes. More... | |
const MSEdgeVector & | getEdges () const |
const std::string & | getID () const |
Returns the id. More... | |
const MSEdge * | getLastEdge () const |
returns the destination edge More... | |
SUMOReal | getLength () const |
const std::map< std::string, std::string > & | getMap () const |
Returns the inner key/value map. More... | |
const std::string & | getParameter (const std::string &key, const std::string &defaultValue) const |
Returns the value for a given key. More... | |
const std::vector < SUMOVehicleParameter::Stop > & | getStops () const |
Returns the stops. More... | |
bool | knowsParameter (const std::string &key) const |
Returns whether the parameter is known. More... | |
MSRoute (const std::string &id, const MSEdgeVector &edges, unsigned int references, const RGBColor *const c, const std::vector< SUMOVehicleParameter::Stop > &stops) | |
Constructor. More... | |
const MSEdge * | operator[] (unsigned index) const |
void | release () const |
deletes the route if there are no further references to it More... | |
void | setID (const std::string &newID) |
resets the id More... | |
unsigned | size () const |
Returns the number of edges to pass. More... | |
int | writeEdgeIDs (OutputDevice &os, const MSEdge *const from, const MSEdge *const upTo=0) const |
Output the edge ids up to but not including the id of the given edge. More... | |
virtual | ~MSRoute () |
Destructor. More... | |
Static Public Member Functions | |
static void | clear () |
Clears the dictionary (delete all known routes, too) More... | |
static bool | dictionary (const std::string &id, const MSRoute *route) |
Adds a route to the dictionary. More... | |
static bool | dictionary (const std::string &id, RandomDistributor< const MSRoute * > *routeDist) |
Adds a route distribution to the dictionary. More... | |
static const MSRoute * | dictionary (const std::string &id) |
Returns the named route or a sample from the named distribution. More... | |
static RandomDistributor < const MSRoute * > * | distDictionary (const std::string &id) |
Returns the named route distribution. More... | |
static unsigned int | getMaxRouteDistSize () |
static void | insertIDs (std::vector< std::string > &into) |
static void | releaseRoute (const MSRoute *route) |
release the route (to be used as function pointer with RandomDistributor) More... | |
static void | setMaxRouteDistSize (unsigned int size) |
State I/O (mesosim only) | |
static void | dict_saveState (OutputDevice &out) |
Saves all known routes into the given stream. More... | |
Protected Attributes | |
std::string | myID |
The name of the object. More... | |
Private Types | |
typedef std::map< std::string, const MSRoute * > | RouteDict |
Definition of the dictionary container. More... | |
typedef std::map< std::string, RandomDistributor< const MSRoute * > * > | RouteDistDict |
Definition of the dictionary container. More... | |
Private Member Functions | |
MSRoute & | operator= (const MSRoute &s) |
Private Attributes | |
const RGBColor *const | myColor |
The color. More... | |
MSEdgeVector | myEdges |
The list of edges to pass. More... | |
unsigned int | myReferenceCounter |
Information by how many vehicles the route is used. More... | |
std::vector < SUMOVehicleParameter::Stop > | myStops |
List of the stops on the parsed route. More... | |
Static Private Attributes | |
static unsigned int | MaxRouteDistSize = std::numeric_limits<unsigned int>::max() |
the maximum size for each routeDistribution More... | |
static RouteDict | myDict |
The dictionary container. More... | |
static RouteDistDict | myDistDict |
The dictionary container. More... | |
|
private |
|
private |
MSRoute::MSRoute | ( | const std::string & | id, |
const MSEdgeVector & | edges, | ||
unsigned int | references, | ||
const RGBColor *const | c, | ||
const std::vector< SUMOVehicleParameter::Stop > & | stops | ||
) |
Constructor.
Definition at line 60 of file MSRoute.cpp.
|
virtual |
|
inherited |
Adds a parameter.
[in] | key | The parameter's name |
[in] | value | The parameter's value |
Definition at line 53 of file Parameterised.cpp.
References Parameterised::myMap.
Referenced by NLHandler::addParam(), SUMORouteHandler::addParam(), PCLoaderOSM::addPOI(), PCLoaderOSM::addPolygon(), and NIImporter_MATSim::EdgesHandler::myStartElement().
|
inherited |
Adds all given parameter.
[in] | mapArg | The keys/values to insert |
Definition at line 59 of file Parameterised.cpp.
References Parameterised::myMap.
|
inherited |
Adds all given parameter.
[in] | p | The keys/values to insert |
Definition at line 67 of file Parameterised.cpp.
References Parameterised::myMap.
void MSRoute::addReference | ( | ) | const |
increments the reference counter for the route
Definition at line 100 of file MSRoute.cpp.
References myReferenceCounter.
Referenced by MSDevice_Vehroutes::addRoute(), MSRouteHandler::closeVehicle(), MSBaseVehicle::MSBaseVehicle(), MSDevice_Vehroutes::MSDevice_Vehroutes(), MSRouteProbe::notifyEnter(), MSDevice_Routing::preInsertionReroute(), MSVehicle::replaceRoute(), and MSBaseVehicle::replaceRouteEdges().
|
inlineinherited |
Adds this object to the given container.
in,filled] | cont The container to add this item to |
Definition at line 114 of file Named.h.
References Named::StoringVisitor::add().
MSRouteIterator MSRoute::begin | ( | ) | const |
Returns the begin of the list of edges to pass.
Definition at line 75 of file MSRoute.cpp.
References myEdges.
Referenced by MSRouteHandler::closeVehicle(), traci::TraCIServer::commandAddVehicle(), GUIVehicle::drawAction_drawRailCarriages(), GUIVehicle::drawRouteHelper(), MSVehicle::enterLaneAtLaneChange(), MSCalibrator::execute(), MSEdge::getDepartLane(), MSVehicle::getRoutePosition(), MSLane::isInsertionSuccess(), TraCIServerAPI_Route::processGet(), TraCIServerAPI_Vehicle::processGet(), MSVehicle::replaceRoute(), MSVehicle::resetRoutePosition(), MSVehicle::saveState(), MSRouteProbe::writeXMLOutput(), and MSDevice_Vehroutes::writeXMLRoute().
|
static |
Clears the dictionary (delete all known routes, too)
Definition at line 160 of file MSRoute.cpp.
References myDict, and myDistDict.
Referenced by MSNet::clearAll().
|
inherited |
Clears the parameter map.
Definition at line 91 of file Parameterised.cpp.
References Parameterised::myMap.
Definition at line 104 of file MSRoute.h.
References myEdges.
Referenced by containsAnyOf(), MSCalibrator::execute(), and MSVehicle::replaceRoute().
Definition at line 206 of file MSRoute.cpp.
References contains().
Referenced by MSTriggeredRerouter::getCurrentReroute(), and MSTriggeredRerouter::hasCurrentReroute().
|
static |
Saves all known routes into the given stream.
[in] | os | The stream to write the routes into (binary) |
Definition at line 224 of file MSRoute.cpp.
References OutputDevice::closeTag(), myDict, myDistDict, OutputDevice::openTag(), SUMO_ATTR_EDGES, SUMO_ATTR_ID, SUMO_ATTR_PROBS, SUMO_ATTR_ROUTES, SUMO_ATTR_STATE, SUMO_TAG_ROUTE, SUMO_TAG_ROUTE_DISTRIBUTION, and OutputDevice::writeAttr().
Referenced by MSStateHandler::saveState().
Adds a route to the dictionary.
Returns true if the route could be added, false if a route (distribution) with the same name already exists.
[in] | id | the id for the new route |
[in] | route | pointer to the route object |
Definition at line 116 of file MSRoute.cpp.
References myDict, and myDistDict.
Referenced by MSInsertionControl::checkFlows(), MSRouteHandler::closeFlow(), MSRouteHandler::closeRoute(), MSRouteHandler::closeRouteDistribution(), MSRouteHandler::closeVehicle(), traci::TraCIServer::commandAddVehicle(), MSCalibrator::execute(), MSRouteProbe::MSRouteProbe(), MSStateHandler::myStartElement(), MSTriggeredRerouter::myStartElement(), MSRouteHandler::openRoute(), MSRouteHandler::openRouteDistribution(), TraCIServerAPI_Route::processGet(), TraCIServerAPI_Route::processSet(), TraCIServerAPI_Vehicle::processSet(), MSBaseVehicle::replaceRouteEdges(), and MSRouteProbe::writeXMLOutput().
|
static |
Adds a route distribution to the dictionary.
Returns true if the distribution could be added, false if a route (distribution) with the same name already exists.
[in] | id | the id for the new route distribution |
[in] | route | pointer to the distribution object |
Definition at line 126 of file MSRoute.cpp.
References myDict, and myDistDict.
|
static |
Returns the named route or a sample from the named distribution.
Returns 0 if no route and no distribution with the given name exists or if the distribution exists and is empty.
[in] | id | the id of the route or the distribution |
Definition at line 136 of file MSRoute.cpp.
References myDict, and myDistDict.
|
static |
Returns the named route distribution.
Returns 0 if no route distribution with the given name exists.
[in] | id | the id of the route distribution |
Definition at line 150 of file MSRoute.cpp.
References myDistDict.
Referenced by MSInsertionControl::add(), and MSRouteProbe::MSRouteProbe().
MSRouteIterator MSRoute::end | ( | ) | const |
Returns the end of the list of edges to pass.
Definition at line 81 of file MSRoute.cpp.
References myEdges.
Referenced by MSVehicle::addStop(), GUIVehicle::drawRouteHelper(), MSCalibrator::execute(), MSVehicle::executeMove(), MSDevice_Tripinfo::generateOutput(), MSVehicle::getBestLanes(), getDistanceBetween(), MSVehicle::hasArrived(), MSBaseVehicle::hasValidRoute(), MSVehicle::planMoveInternal(), TraCIServerAPI_Route::processGet(), TraCIServerAPI_Vehicle::processGet(), MSVehicle::resetRoutePosition(), MSVehicle::willPass(), and MSRouteProbe::writeXMLOutput().
const RGBColor & MSRoute::getColor | ( | ) | const |
Returns the color.
Definition at line 293 of file MSRoute.cpp.
References RGBColor::DEFAULT_COLOR, and myColor.
Referenced by MSBaseVehicle::replaceRouteEdges().
SUMOReal MSRoute::getDistanceBetween | ( | SUMOReal | fromPos, |
SUMOReal | toPos, | ||
const MSEdge * | fromEdge, | ||
const MSEdge * | toEdge | ||
) | const |
Compute the distance between 2 given edges on this route, including the length of internal lanes.
[in] | fromPos | position on the first edge, at wich the computed distance begins |
[in] | toPos | position on the last edge, at which the coumputed distance endsance |
[in] | fromEdge | edge at wich computation begins |
[in] | toEdge | edge at which distance computation shall stop |
Definition at line 250 of file MSRoute.cpp.
References end(), max, myEdges, and SUMOReal.
Referenced by TraCIServerAPI_Vehicle::commandDistanceRequest(), TraCIServerAPI_Simulation::commandDistanceRequest(), and MSVehicle::getDistanceToPosition().
|
inline |
Definition at line 122 of file MSRoute.h.
References myEdges.
Referenced by traci::TraCIServer::commandAddVehicle(), MSDevice_BTsender::generateOutput(), GUIVehicle::getPreviousLane(), MSVehicle::replaceRoute(), GUIVehicle::setFunctionalColor(), TraCIServerAPI_Vehicle::vtdMap_matchingEdgeLane(), and TraCIServerAPI_Vehicle::vtdMap_matchingNearest().
|
inlineinherited |
Returns the id.
Definition at line 60 of file Named.h.
References Named::myID.
Referenced by NIImporter_SUMO::_loadNetwork(), Named::StoringVisitor::add(), MSDetectorControl::add(), RORouteDef::addAlternative(), MSNet::addBusStop(), NBLoadedSUMOTLDef::addConnection(), NLHandler::addConnection(), RODFDetectorCon::addDetector(), RONet::addEdge(), ROJTREdge::addFollowerProbability(), MSTLLogicControl::TLSLogicVariants::addLogic(), RONet::addNode(), NIImporter_SUMO::addPhase(), RONet::addRouteDef(), NBDistrict::addSink(), NBDistrict::addSource(), NBTrafficLightLogic::addStep(), MSRouteHandler::addStop(), NIXMLTrafficLightsHandler::addTlConnection(), NIVissimDisturbance::addToNode(), MSVehicle::addTraciStop(), GUITrafficLightLogicWrapper::begin2TrackPhases(), MSPerson::MSPersonStage_Driving::beginEventOutput(), MSPerson::MSPersonStage_Waiting::beginEventOutput(), NIVisumTL::build(), RODFNet::buildApproachList(), MS_E2_ZS_CollectorOverLanes::buildCollector(), NIImporter_VISUM::buildDistrictNode(), NIVissimConnection::buildEdgeConnections(), RODFNet::buildEdgeFlowMap(), NBEdge::buildInnerEdges(), NGEdge::buildNBEdge(), NIVissimEdge::buildNBEdge(), NBRampsComputer::buildOffRamp(), NBRampsComputer::buildOnRamp(), MSSimpleTrafficLightLogic::changeStepAndDuration(), NBEdge::checkGeometry(), MSVehicleTransfer::checkInsertions(), ODDistrictHandler::closeDistrict(), NLHandler::closeEdge(), RORouteHandler::closeRouteDistribution(), RORouteHandler::closeVehicle(), NBTrafficLightDefinition::collectAllLinks(), NBTrafficLightDefinition::collectEdges(), ROJTRRouter::compute(), NBTrafficLightDefinition::compute(), NBNode::computeInternalLaneShape(), NBEdge::computeLaneShapes(), NBNode::computeLogic(), NBNode::computeNodeShape(), RODFNet::computeRoutesFor(), NBTrafficLightLogicCont::computeSingleLogic(), NBTurningDirectionsComputer::computeTurnDirectionsForNode(), NGNet::connect(), NBEdge::connections_sorter(), MSAbstractLaneChangeModel::continueLaneChangeManeuver(), NLDetectorBuilder::convUncontE2PosLength(), GUINet::createTLWrapper(), MSLane::detectCollisions(), NIVissimDistrictConnection::dict_BuildDistricts(), MSPerson::MSPersonStage_Driving::endEventOutput(), MSPerson::MSPersonStage_Waiting::endEventOutput(), MSE3Collector::enter(), MSCalibrator::execute(), Command_SaveTLSState::execute(), Command_SaveTLSSwitchStates::execute(), Command_SaveTLSSwitches::execute(), MSVTypeProbe::execute(), MSVehicle::executeMove(), MSLane::executeMovements(), NBNodeCont::extract(), NBTrafficLightLogicCont::extract(), NBEdgeCont::extract(), RODFDetectorCon::getAggFlowFor(), RODFDetectorCon::getAnyDetectorForEdge(), MSNet::getBusStopID(), RODFNet::getDetectorEdge(), MS_E2_ZS_CollectorOverLanes::getLanePredeccessorLanes(), AGStreet::getName(), NIImporter_VISUM::getNamedEdgeContinuating(), GUITrafficLightLogicWrapper::getPopUpMenu(), NLTriggerBuilder::getPosition(), NLDetectorBuilder::getPositionChecking(), NBNode::getPossiblySplittedIncoming(), NBNode::getPossiblySplittedOutgoing(), NIImporter_VISUM::getReversedContinuating(), RODFDetectorCon::guessEmptyFlows(), GUITLLogicPhasesTrackerWindow::GUITLLogicPhasesTrackerWindow(), NBEdgeCont::ignoreFilterMatch(), MSActuatedTrafficLightLogic::init(), MSAgentbasedTrafficLightLogic::init(), NIImporter_SUMO::initTrafficLightLogic(), NIXMLTrafficLightsHandler::initTrafficLightLogic(), NBDistrictCont::insert(), NBTrafficLightLogicCont::insert(), NBNodeCont::insert(), NBEdgeCont::insert(), NBNode::invalidateTLS(), MSTLLogicControl::isActive(), RODFNet::isDestination(), RODFNet::isFalseSource(), RODFNet::isSource(), NBEdgeCont::joinSameNodeConnectingEdges(), MSE3Collector::leave(), NIImporter_OpenDrive::loadNetwork(), NBRampsComputer::moveRampRight(), MSPerson::MSPersonStage_Waiting::MSPersonStage_Waiting(), MSVehicle::MSVehicle(), NBOwnTLDef::myCompute(), NBLoadedTLDef::myCompute(), NIXMLTrafficLightsHandler::myEndElement(), NIXMLEdgesHandler::myEndElement(), NIImporter_SUMO::myEndElement(), NIXMLConnectionsHandler::myStartElement(), MSLaneSpeedTrigger::myStartElement(), MSTriggeredRerouter::myStartElement(), NBConnection::NBConnection(), NBRequest::NBRequest(), MSDevice_Example::notifyEnter(), MSDevice_Tripinfo::notifyEnter(), MSCalibrator::VehicleRemover::notifyEnter(), MSDevice_Person::notifyLeave(), MSDevice_Example::notifyLeave(), MSDevice_Tripinfo::notifyLeave(), MSDevice_Example::notifyMove(), GUIViewTraffic::onGamingClick(), RORouteHandler::openRoute(), Named::ComparatorIdLess::operator()(), NBTurningDirectionsComputer::combination_by_angle_sorter::operator()(), RODFNet::idComp::operator()(), NBOwnTLDef::edge_by_incoming_priority_sorter::operator()(), NBNetBuilder::by_id_sorter::operator()(), NBContHelper::same_connection_edge_sorter::operator()(), NBNode::nodes_by_id_sorter::operator()(), MSEdge::by_id_sorter::operator()(), NIImporter_VISUM::parse_EdgePolys(), NIImporter_VISUM::parse_Lanes(), NIImporter_VISUM::parse_LanesConnections(), NIImporter_VISUM::parse_Turns(), NIImporter_VISUM::parse_TurnsToSignalGroups(), NIXMLConnectionsHandler::parseDeprecatedLaneDefinition(), NIXMLConnectionsHandler::parseLaneBound(), NBLoadedTLDef::SignalGroup::patchTYellow(), AGStreet::print(), TraCIServerAPI_TLS::processGet(), TraCIServerAPI_Lane::processGet(), TraCIServerAPI_InductionLoop::processGet(), TraCIServerAPI_Vehicle::processGet(), TraCIServerAPI_Vehicle::processSet(), NWWriter_SUMO::prohibitionConnection(), NBEdgeCont::recheckPostProcessConnections(), NBLoadedTLDef::SignalGroup::remapIncoming(), NBLoadedTLDef::SignalGroup::remapOutgoing(), NBLoadedSUMOTLDef::removeConnection(), NBNode::removeSelfLoops(), NBEdgeCont::removeUnwishedEdges(), NBNodeCont::removeUnwishedNodes(), NBNodeCont::rename(), NBEdgeCont::rename(), NBConnection::replaceFrom(), MSBaseVehicle::replaceRouteEdges(), NBConnection::replaceTo(), NIImporter_DlrNavteq::TrafficlightsHandler::report(), NIXMLTrafficLightsHandler::retrieveLaneIndex(), RODFNet::revalidateFlows(), PCPolyContainer::save(), RONet::saveAndRemoveRoutesUntil(), MSBaseVehicle::saveState(), NBNodeCont::setAsTLControlled(), NBEdge::setControllingTLInformation(), NIXMLEdgesHandler::setNodes(), NBOwnTLDef::setTLControllingInformation(), NBLoadedSUMOTLDef::setTLControllingInformation(), NBLoadedTLDef::setTLControllingInformation(), NBEdgeCont::splitAt(), GUITrafficLightLogicWrapper::switchTLSLogic(), NIXMLConnectionsHandler::validateLaneInfo(), TraCIServerAPI_Vehicle::vtdMap_matchingEdgeLane(), TraCIServerAPI_Vehicle::vtdMap_matchingRoutePosition(), MSEmissionExport::write(), MSFCDExport::write(), MSInstantInductLoop::write(), NBSign::writeAsPOI(), NWWriter_SUMO::writeConnection(), NWWriter_SUMO::writeDistrict(), MSFullExport::writeEdge(), MSXMLRawOut::writeEdge(), NWWriter_SUMO::writeEdge(), MSMeanData::writeEdge(), NWWriter_XML::writeEdgesAndConnections(), RODFDetector::writeEmitterDefinition(), RODFDetectorCon::writeEmitterPOIs(), RODFDetectorCon::writeEmitters(), RODFDetectorCon::writeEndRerouterDetectors(), NWWriter_SUMO::writeInternalConnections(), NWWriter_SUMO::writeJunction(), MSQueueExport::writeLane(), MSFullExport::writeLane(), NWWriter_DlrNavteq::writeLinksUnsplitted(), NWWriter_OpenDrive::writeNetwork(), NWWriter_XML::writeNodes(), NWWriter_DlrNavteq::writeNodesUnsplitted(), NWWriter_SUMO::writeRoundabout(), RODFDetectorCon::writeSpeedTrigger(), NWWriter_DlrNavteq::writeTrafficSignals(), MSInductLoop::writeTypedXMLOutput(), RODFDetectorCon::writeValidationDetectors(), MSFullExport::writeVehicles(), MSRouteProbe::writeXMLOutput(), and MSE2Collector::writeXMLOutput().
const MSEdge * MSRoute::getLastEdge | ( | ) | const |
returns the destination edge
Definition at line 93 of file MSRoute.cpp.
References myEdges.
Referenced by MSBaseVehicle::calculateArrivalPos(), MSLane::isInsertionSuccess(), MSTriggeredRerouter::notifyEnter(), and MSBaseVehicle::reroute().
SUMOReal MSRoute::getLength | ( | ) | const |
Definition at line 240 of file MSRoute.cpp.
References myEdges, and SUMOReal.
Referenced by MSDevice_Tripinfo::generateOutput().
|
inlineinherited |
Returns the inner key/value map.
Definition at line 106 of file Parameterised.h.
References Parameterised::myMap.
Referenced by PCPolyContainer::save().
|
inlinestatic |
Definition at line 200 of file MSRoute.h.
References MaxRouteDistSize.
Referenced by MSRouteProbe::MSRouteProbe(), MSStateHandler::myStartElement(), MSRouteHandler::openRouteDistribution(), and MSRouteProbe::writeXMLOutput().
|
inherited |
Returns the value for a given key.
[in] | key | The key to ask for |
[in] | defaultValue | The default value to return if no value is stored under the key |
Definition at line 81 of file Parameterised.cpp.
References Parameterised::myMap.
Referenced by MSDevice_Example::buildVehicleDevices(), MSTLLogicControl::WAUTSwitchProcedure::getGSPValue(), MSTLLogicControl::WAUTSwitchProcedure_Stretch::getStretchAreaNo(), MSTLLogicControl::WAUTSwitchProcedure_Stretch::getStretchBereichDef(), MSAgentbasedTrafficLightLogic::init(), MSActuatedTrafficLightLogic::MSActuatedTrafficLightLogic(), MSAgentbasedTrafficLightLogic::MSAgentbasedTrafficLightLogic(), and TraCIServerAPI_Vehicle::vtdMap_matchingNearest().
const std::vector< SUMOVehicleParameter::Stop > & MSRoute::getStops | ( | ) | const |
Returns the stops.
Definition at line 302 of file MSRoute.cpp.
References myStops.
Referenced by MSVehicle::MSVehicle(), and MSBaseVehicle::replaceRouteEdges().
|
static |
Definition at line 173 of file MSRoute.cpp.
References myDict, and myDistDict.
Referenced by TraCIServerAPI_Route::processGet().
|
inherited |
Returns whether the parameter is known.
[in] | key | The key to ask for |
Definition at line 75 of file Parameterised.cpp.
References Parameterised::myMap.
Referenced by MSDevice_Example::buildVehicleDevices(), and TraCIServerAPI_Vehicle::vtdMap_matchingNearest().
const MSEdge * MSRoute::operator[] | ( | unsigned | index) | const |
Definition at line 218 of file MSRoute.cpp.
References myEdges.
void MSRoute::release | ( | ) | const |
deletes the route if there are no further references to it
Definition at line 106 of file MSRoute.cpp.
References myDict, Named::myID, and myReferenceCounter.
Referenced by MSDevice_Vehroutes::addRoute(), MSRouteHandler::closeVehicle(), releaseRoute(), MSVehicle::replaceRoute(), MSBaseVehicle::replaceRouteEdges(), MSBaseVehicle::~MSBaseVehicle(), and MSDevice_Vehroutes::~MSDevice_Vehroutes().
|
inlinestatic |
release the route (to be used as function pointer with RandomDistributor)
Definition at line 192 of file MSRoute.h.
References release().
Referenced by MSRouteProbe::MSRouteProbe(), MSStateHandler::myStartElement(), MSRouteHandler::openRouteDistribution(), and MSRouteProbe::writeXMLOutput().
|
inlineinherited |
resets the id
[in] | newID | The new id of this object |
Definition at line 68 of file Named.h.
References Named::myID.
Referenced by NBNodeCont::rename(), and NBEdgeCont::rename().
|
inlinestatic |
Definition at line 196 of file MSRoute.h.
References MaxRouteDistSize, and size().
Referenced by MSFrame::setMSGlobals().
unsigned MSRoute::size | ( | ) | const |
Returns the number of edges to pass.
Definition at line 87 of file MSRoute.cpp.
References myEdges.
Referenced by MSEdge::getDepartLane(), TraCIServerAPI_Route::processGet(), TraCIServerAPI_Vehicle::processGet(), setMaxRouteDistSize(), and MSDevice_Vehroutes::writeXMLRoute().
int MSRoute::writeEdgeIDs | ( | OutputDevice & | os, |
const MSEdge *const | from, | ||
const MSEdge *const | upTo = 0 |
||
) | const |
Output the edge ids up to but not including the id of the given edge.
[in] | os | The stream to write the routes into (binary) |
[in] | from | The first edge to be written |
[in] | upTo | The first edge that shall not be written |
Definition at line 185 of file MSRoute.cpp.
References myEdges.
Referenced by MSDevice_Vehroutes::writeXMLRoute().
the maximum size for each routeDistribution
Definition at line 231 of file MSRoute.h.
Referenced by getMaxRouteDistSize(), and setMaxRouteDistSize().
|
private |
|
staticprivate |
The dictionary container.
Definition at line 222 of file MSRoute.h.
Referenced by clear(), dict_saveState(), dictionary(), insertIDs(), and release().
|
staticprivate |
The dictionary container.
Definition at line 228 of file MSRoute.h.
Referenced by clear(), dict_saveState(), dictionary(), distDictionary(), and insertIDs().
|
private |
The list of edges to pass.
Definition at line 206 of file MSRoute.h.
Referenced by begin(), contains(), end(), getDistanceBetween(), getEdges(), getLastEdge(), getLength(), operator[](), size(), and writeEdgeIDs().
|
protectedinherited |
The name of the object.
Definition at line 121 of file Named.h.
Referenced by GUI_E2_ZS_CollectorOverLanes::buildCollector(), RODFDetector::buildDestinationDistribution(), NGEdge::buildNBEdge(), NGNode::buildNBNode(), MSCalibrator::execute(), Named::getID(), NBEdge::getLaneID(), NBEdge::getLaneIDInsecure(), ROEdge::getStoredEffort(), ROEdge::getTravelTime(), MSActuatedTrafficLightLogic::init(), MSAgentbasedTrafficLightLogic::init(), MSCalibrator::init(), NBEdge::init(), MSCalibrator::myStartElement(), MSCalibrator::VehicleRemover::notifyEnter(), RORouteDef::preComputeCurrentRoute(), NBEdge::reinitNodes(), release(), RORouteDef::repairCurrentRoute(), Named::setID(), NBEdge::splitGeometry(), RODFDetector::writeEmitterDefinition(), MSXMLRawOut::writeLane(), NBNode::writeLogic(), RODFDetector::writeSingleSpeedTrigger(), MSCalibrator::writeXMLOutput(), MSE3Collector::writeXMLOutput(), and MSMeanData::writeXMLOutput().
|
mutableprivate |
Information by how many vehicles the route is used.
Definition at line 209 of file MSRoute.h.
Referenced by addReference(), and release().
|
private |
List of the stops on the parsed route.
Definition at line 215 of file MSRoute.h.
Referenced by getStops().