|
SUMO - Simulation of Urban MObility
|
A DFROUTER-network. More...
#include <RODFNet.h>
Data Structures | |
| class | DFRouteDescByTimeComperator |
| struct | IterationEdge |
Public Member Functions | |
| void | buildApproachList () |
| void | buildDetectorDependencies (RODFDetectorCon &detectors) |
| void | buildEdgeFlowMap (const RODFDetectorFlows &flows, const RODFDetectorCon &detectors, SUMOTime startTime, SUMOTime endTime, SUMOTime stepOffset) |
| void | buildRoutes (RODFDetectorCon &det, bool allEndFollower, bool keepUnfoundEnds, bool includeInBetween, bool keepShortestOnly, int maxFollowingLength) const |
| void | closeOutput () throw () |
| closes the file output for computed routes | |
| void | computeTypes (RODFDetectorCon &dets, bool sourcesStrict) const |
| SUMOReal | getAbsPos (const RODFDetector &det) const |
| const std::vector< std::string > & | getDetectorList (ROEdge *edge) const |
| const std::map< std::string, ROEdge * > & | getEdgeMap () const |
| unsigned int | getEdgeNo () const |
| Returns the number of edges thenetwork contains. | |
| ROEdge * | getRandomDestination () throw () |
| Returns a random edge which may be used as an ending point. | |
| const ROEdge * | getRandomDestination () const throw () |
| Returns a random edge which may be used as an ending point. | |
| ROEdge * | getRandomSource () throw () |
| Returns a random edge which may be used as a starting point. | |
| const ROEdge * | getRandomSource () const throw () |
| Returns a random edge which may be used as a starting point. | |
| bool | hasDetector (ROEdge *edge) const |
| bool | hasRestrictions () const |
| void | mesoJoin (RODFDetectorCon &detectors, RODFDetectorFlows &flows) |
| void | openOutput (const std::string &filename, bool useAlternatives) throw (IOError) |
| Opens the output for computed routes. | |
| void | removeEmptyDetectors (RODFDetectorCon &detectors, RODFDetectorFlows &flows) |
| void | reportEmptyDetectors (RODFDetectorCon &detectors, RODFDetectorFlows &flows) |
| void | revalidateFlows (const RODFDetectorCon &detectors, RODFDetectorFlows &flows, SUMOTime startTime, SUMOTime endTime, SUMOTime stepOffset) |
| RODFNet (bool amInHighwayMode) throw () | |
| Constructor. | |
| void | setRestrictionFound () |
| ~RODFNet () throw () | |
| Destructor. | |
Insertion and retrieval of graph parts | |
| virtual bool | addEdge (ROEdge *edge) throw () |
| ROEdge * | getEdge (const std::string &name) const throw () |
| Retrieves an edge from the network. | |
| void | addNode (RONode *node) throw () |
| RONode * | getNode (const std::string &id) const throw () |
| Retrieves an node from the network. | |
Insertion and retrieval of vehicle types, vehicles, routes, and route definitions | |
| virtual bool | addVehicleType (SUMOVTypeParameter *type) throw () |
| SUMOVTypeParameter * | getVehicleTypeSecure (const std::string &id) throw () |
| Retrieves the named vehicle type. | |
| bool | addRouteDef (RORouteDef *def) throw () |
| RORouteDef * | getRouteDef (const std::string &name) const throw () |
| Returns the named route definition. | |
| virtual bool | addVehicle (const std::string &id, ROVehicle *veh) throw () |
Processing stored vehicle definitions | |
| SUMOTime | saveAndRemoveRoutesUntil (OptionsCont &options, SUMOAbstractRouter< ROEdge, ROVehicle > &router, SUMOTime time) |
| Computes routes described by their definitions and saves them. | |
| virtual bool | furtherStored () |
| Returns the information whether further vehicles are stored. | |
Protected Member Functions | |
| void | buildDetectorEdgeDependencies (RODFDetectorCon &dets) const |
| void | checkSourceAndDestinations () const |
| Initialises the lists of source and destination edges. | |
| bool | computeRoute (OptionsCont &options, SUMOAbstractRouter< ROEdge, ROVehicle > &router, const ROVehicle *const veh) |
| void | computeRoutesFor (ROEdge *edge, RODFRouteDesc &base, int no, bool keepUnfoundEnds, bool keepShortestOnly, std::vector< ROEdge * > &visited, const RODFDetector &det, RODFRouteCont &into, const RODFDetectorCon &detectors, int maxFollowingLength, std::vector< ROEdge * > &seen) const |
| ROEdge * | getDetectorEdge (const RODFDetector &det) const |
| bool | hasApproached (ROEdge *edge) const |
| bool | hasApproaching (ROEdge *edge) const |
| bool | hasInBetweenDetectorsOnly (ROEdge *edge, const RODFDetectorCon &detectors) const |
| bool | hasSourceDetector (ROEdge *edge, const RODFDetectorCon &detectors) const |
| bool | isDestination (const RODFDetector &det, const RODFDetectorCon &detectors) const |
| bool | isDestination (const RODFDetector &det, ROEdge *edge, std::vector< ROEdge * > &seen, const RODFDetectorCon &detectors) const |
| bool | isFalseSource (const RODFDetector &det, ROEdge *edge, std::vector< ROEdge * > &seen, const RODFDetectorCon &detectors) const |
| bool | isFalseSource (const RODFDetector &det, const RODFDetectorCon &detectors) const |
| bool | isSource (const RODFDetector &det, ROEdge *edge, std::vector< ROEdge * > &seen, const RODFDetectorCon &detectors, bool strict) const |
| bool | isSource (const RODFDetector &det, const RODFDetectorCon &detectors, bool strict) const |
| void | revalidateFlows (const RODFDetector *detector, RODFDetectorFlows &flows, SUMOTime startTime, SUMOTime endTime, SUMOTime stepOffset) |
Protected Attributes | |
| std::vector< ROEdge * > | myDestinationEdges |
| List of destination edges. | |
| unsigned int | myDiscardedRouteNo |
| The number of discarded routes. | |
| NamedObjectCont< ROEdge * > | myEdges |
| Known edges. | |
| bool | myHaveRestrictions |
| Whether the network contains edges which not all vehicles may pass. | |
| NamedObjectCont< RONode * > | myNodes |
| Known nodes. | |
| unsigned int | myReadRouteNo |
| The number of read routes. | |
| OutputDevice * | myRouteAlternativesOutput |
| The file to write the computed route alternatives into. | |
| NamedObjectCont< RORouteDef * > | myRoutes |
| Known routes. | |
| OutputDevice * | myRoutesOutput |
| The file to write the computed routes into. | |
| std::vector< ROEdge * > | mySourceEdges |
| List of source edges. | |
| ROVehicleCont | myVehicles |
| Known vehicles. | |
| NamedObjectCont < SUMOVTypeParameter * > | myVehicleTypes |
| Known vehicle types. | |
| std::set< std::string > | myVehIDs |
| Known vehicle ids. | |
| unsigned int | myWrittenRouteNo |
| The number of written routes. | |
Private Attributes | |
| bool | myAmInHighwayMode |
| std::map< ROEdge *, std::vector< ROEdge * > > | myApproachedEdges |
| Map of edge name->list of names of edges approached by this edge. | |
| std::map< ROEdge *, std::vector< ROEdge * > > | myApproachingEdges |
| Map of edge name->list of names of this edge approaching edges. | |
| std::map< std::string, ROEdge * > | myDetectorEdges |
| std::map< ROEdge *, std::vector< std::string > > | myDetectorsOnEdges |
| std::vector< std::string > | myDisallowedEdges |
| List of ids of edges that shall not be used. | |
| size_t | myInBetweenNumber |
| size_t | myInvalidNumber |
| bool | myKeepTurnarounds |
| size_t | mySinkNumber |
| size_t | mySourceNumber |
| RODFNet::RODFNet | ( | bool | amInHighwayMode | ) | throw () |
Constructor.
| [in] | amInHighwayMode | Whether search for following edges shall stop at slow edges |
Definition at line 51 of file RODFNet.cpp.
References OptionsCont::getBool(), OptionsCont::getOptions(), and OptionsCont::getStringVector().
| RODFNet::~RODFNet | ( | ) | throw () |
Destructor.
Definition at line 59 of file RODFNet.cpp.
Definition at line 76 of file RONet.cpp.
References WRITE_ERROR.
Referenced by RONetHandler::parseEdge().
| void RONet::addNode | ( | RONode * | node | ) | throw () [inherited] |
Definition at line 87 of file RONet.cpp.
References WRITE_ERROR.
Referenced by RONetHandler::parseEdge(), and RONetHandler::parseJunction().
| bool RONet::addRouteDef | ( | RORouteDef * | def | ) | throw () [inherited] |
Definition at line 96 of file RONet.cpp.
Referenced by RORDGenerator_ODAmounts::FlowDef::addSingleRoute(), and RORDGenerator_ODAmounts::myEndFlowAmountDef().
Definition at line 165 of file RONet.cpp.
References WRITE_ERROR.
Referenced by RORDGenerator_ODAmounts::FlowDef::addSingleRoute(), and RORDLoader_SUMOBase::closeVehicle().
| bool RONet::addVehicleType | ( | SUMOVTypeParameter * | type | ) | throw () [virtual, inherited] |
Definition at line 154 of file RONet.cpp.
References WRITE_ERROR.
| void RODFNet::buildApproachList | ( | ) |
Definition at line 64 of file RODFNet.cpp.
References RONet::getEdgeMap(), ROEdge::getFollower(), ROEdge::getFromNode(), ROEdge::getID(), ROEdge::getNoFollowing(), ROEdge::getToNode(), myApproachedEdges, myApproachingEdges, myDisallowedEdges, and myKeepTurnarounds.
Referenced by main().
| void RODFNet::buildDetectorDependencies | ( | RODFDetectorCon & | detectors | ) |
Definition at line 1022 of file RODFNet.cpp.
References buildDetectorEdgeDependencies(), RODFDetectorCon::getDetector(), RODFDetector::getRouteVector(), RODFDetector::hasRoutes(), myDetectorEdges, and myDetectorsOnEdges.
Referenced by startComputation().
| void RODFNet::buildDetectorEdgeDependencies | ( | RODFDetectorCon & | dets | ) | const [protected] |
Definition at line 96 of file RODFNet.cpp.
References getDetectorEdge(), RODFDetectorCon::getDetectors(), myDetectorEdges, and myDetectorsOnEdges.
Referenced by buildDetectorDependencies(), buildRoutes(), computeTypes(), and mesoJoin().
| void RODFNet::buildEdgeFlowMap | ( | const RODFDetectorFlows & | flows, |
| const RODFDetectorCon & | detectors, | ||
| SUMOTime | startTime, | ||
| SUMOTime | endTime, | ||
| SUMOTime | stepOffset | ||
| ) |
Definition at line 947 of file RODFNet.cpp.
References FlowDef::fLKW, RODFDetectorCon::getDetector(), RODFDetectorFlows::getFlowDefs(), ROEdge::getID(), RODFDetector::getPos(), ROEdge::getSpeed(), FlowDef::isLKW, RODFDetectorFlows::knows(), MAX2(), myDetectorsOnEdges, FlowDef::qLKW, FlowDef::qPKW, SUMOReal, FlowDef::vLKW, FlowDef::vPKW, and WRITE_MESSAGE.
Referenced by startComputation().
| void RODFNet::buildRoutes | ( | RODFDetectorCon & | det, |
| bool | allEndFollower, | ||
| bool | keepUnfoundEnds, | ||
| bool | includeInBetween, | ||
| bool | keepShortestOnly, | ||
| int | maxFollowingLength | ||
| ) | const |
!!;
!!routes->removeIllegal(illegals);
!!;
Definition at line 351 of file RODFNet.cpp.
References RODFRouteCont::addAllEndFollower(), BETWEEN_DETECTOR, buildDetectorEdgeDependencies(), computeRoutesFor(), RODFRouteDesc::distance, RODFRouteDesc::distance2Last, RODFRouteDesc::duration2Last, RODFRouteDesc::duration_2, RODFRouteDesc::edges2Pass, RODFRouteDesc::endDetectorEdge, RODFRouteDesc::factor, RODFRouteCont::get(), RODFDetectorCon::getDetector(), getDetectorEdge(), RODFDetectorCon::getDetectors(), ROEdge::getLength(), ROEdge::getSpeed(), RODFDetector::getType(), RODFRouteDesc::lastDetectorEdge, myDetectorsOnEdges, RODFRouteDesc::overallProb, SOURCE_DETECTOR, and SUMOReal.
Referenced by startComputation().
| void RONet::checkSourceAndDestinations | ( | ) | const [protected, inherited] |
Initialises the lists of source and destination edges.
Definition at line 317 of file RONet.cpp.
References ROEdge::ET_SINK, ROEdge::ET_SOURCE, NamedObjectCont< T >::getMyMap(), ROEdge::getType(), RONet::myDestinationEdges, RONet::myEdges, and RONet::mySourceEdges.
Referenced by RONet::getRandomDestination(), and RONet::getRandomSource().
| void RONet::closeOutput | ( | ) | throw () [inherited] |
closes the file output for computed routes
Definition at line 118 of file RONet.cpp.
References OutputDevice::close(), RONet::myRouteAlternativesOutput, and RONet::myRoutesOutput.
Referenced by computeRoutes().
| bool RONet::computeRoute | ( | OptionsCont & | options, |
| SUMOAbstractRouter< ROEdge, ROVehicle > & | router, | ||
| const ROVehicle *const | veh | ||
| ) | [protected, inherited] |
Definition at line 177 of file RONet.cpp.
References RORouteDef::addAlternative(), RORouteDef::buildCurrentRoute(), OptionsCont::getBool(), ROVehicle::getDepartureTime(), MsgHandler::getErrorInstance(), ROVehicle::getID(), ROVehicle::getRouteDefinition(), MsgHandler::getWarningInstance(), MsgHandler::inform(), ReferencedItem::isSaved(), RORoute::recheckForLoops(), and RORoute::size().
Referenced by RONet::saveAndRemoveRoutesUntil().
| void RODFNet::computeRoutesFor | ( | ROEdge * | edge, |
| RODFRouteDesc & | base, | ||
| int | no, | ||
| bool | keepUnfoundEnds, | ||
| bool | keepShortestOnly, | ||
| std::vector< ROEdge * > & | visited, | ||
| const RODFDetector & | det, | ||
| RODFRouteCont & | into, | ||
| const RODFDetectorCon & | detectors, | ||
| int | maxFollowingLength, | ||
| std::vector< ROEdge * > & | seen | ||
| ) | const [protected] |
!!! //toDiscard.push_back(current);
!!
Definition at line 193 of file RODFNet.cpp.
References RODFRouteCont::addRouteDesc(), RODFRouteDesc::distance, RODFRouteDesc::distance2Last, RODFRouteDesc::duration2Last, RODFRouteDesc::duration_2, RODFRouteDesc::edges2Pass, RODFRouteDesc::endDetectorEdge, RODFRouteDesc::factor, getDetectorEdge(), OptionsCont::getFloat(), RODFDetector::getID(), OptionsCont::getOptions(), ROEdge::getSpeed(), hasApproached(), hasDetector(), hasInBetweenDetectorsOnly(), hasSourceDetector(), RODFRouteDesc::lastDetectorEdge, myAmInHighwayMode, myApproachedEdges, RODFRouteDesc::passedNo, RODFRouteCont::removeRouteDesc(), SUMOReal, and WRITE_WARNING.
Referenced by buildRoutes().
| void RODFNet::computeTypes | ( | RODFDetectorCon & | dets, |
| bool | sourcesStrict | ||
| ) | const |
Definition at line 116 of file RODFNet.cpp.
References BETWEEN_DETECTOR, buildDetectorEdgeDependencies(), DISCARDED_DETECTOR, RODFDetectorCon::getDetectors(), isDestination(), isFalseSource(), isSource(), myInBetweenNumber, myInvalidNumber, mySinkNumber, mySourceNumber, PROGRESS_BEGIN_MESSAGE, PROGRESS_DONE_MESSAGE, SINK_DETECTOR, SOURCE_DETECTOR, toString(), TYPE_NOT_DEFINED, and WRITE_MESSAGE.
Referenced by startComputation().
| bool RONet::furtherStored | ( | ) | [virtual, inherited] |
Returns the information whether further vehicles are stored.
Definition at line 262 of file RONet.cpp.
References RONet::myVehicles, and NamedObjectCont< T >::size().
Referenced by ROLoader::processRoutesStepWise().
| SUMOReal RODFNet::getAbsPos | ( | const RODFDetector & | det | ) | const |
Definition at line 689 of file RODFNet.cpp.
References getDetectorEdge(), ROEdge::getLength(), and RODFDetector::getPos().
Referenced by isDestination(), and isSource().
| ROEdge * RODFNet::getDetectorEdge | ( | const RODFDetector & | det | ) | const [protected] |
Definition at line 644 of file RODFNet.cpp.
References RONet::getEdge(), RODFDetector::getID(), and RODFDetector::getLaneID().
Referenced by buildDetectorEdgeDependencies(), buildRoutes(), computeRoutesFor(), getAbsPos(), isDestination(), isFalseSource(), isSource(), and revalidateFlows().
| const std::vector< std::string > & RODFNet::getDetectorList | ( | ROEdge * | edge | ) | const |
Definition at line 683 of file RODFNet.cpp.
References myDetectorsOnEdges.
| ROEdge* RONet::getEdge | ( | const std::string & | name | ) | const throw () [inline, inherited] |
Retrieves an edge from the network.
This is not very pretty, but necessary, though, as routes run over instances, not over ids.
| [in] | name | The name of the edge to retrieve |
Definition at line 100 of file RONet.h.
References NamedObjectCont< T >::get(), and RONet::myEdges.
Referenced by getDetectorEdge(), RORDLoader_TripDefs::getEdge(), loadJTRDefinitions(), RONetHandler::parseConnectedEdge(), RONetHandler::parseConnection(), RONetHandler::parseDistrictEdge(), AGActivityGenHandler::parseStreets(), RODFDetectorCon::writeEmitters(), and RODFDetectorCon::writeSpeedTrigger().
| const std::map< std::string, ROEdge * > & RONet::getEdgeMap | ( | ) | const [inherited] |
Definition at line 343 of file RONet.cpp.
References NamedObjectCont< T >::getMyMap(), and RONet::myEdges.
Referenced by buildApproachList(), AGCity::completeStreets(), initNet(), and ROLoader::loadWeights().
| unsigned int RONet::getEdgeNo | ( | ) | const [inherited] |
Returns the number of edges thenetwork contains.
Definition at line 337 of file RONet.cpp.
References RONet::myEdges, and NamedObjectCont< T >::size().
Referenced by computeRoutes(), and main().
| RONode* RONet::getNode | ( | const std::string & | id | ) | const throw () [inline, inherited] |
Retrieves an node from the network.
| [in] | name | The name of the node to retrieve |
Definition at line 122 of file RONet.h.
References NamedObjectCont< T >::get(), and RONet::myNodes.
Referenced by RONetHandler::parseEdge(), and RONetHandler::parseJunction().
| const ROEdge * RONet::getRandomDestination | ( | ) | const throw () [inherited] |
Returns a random edge which may be used as an ending point.
If the list of possible destinations (roads with no successor, "myDestinationEdges") is empty, it is tried to be built, first.
Definition at line 305 of file RONet.cpp.
References RONet::checkSourceAndDestinations(), RandHelper::getRandomFrom(), and RONet::myDestinationEdges.
| ROEdge * RONet::getRandomDestination | ( | ) | throw () [inherited] |
Returns a random edge which may be used as an ending point.
If the list of possible destinations (roads with no successor, "myDestinationEdges") is empty, it is tried to be built, first.
Definition at line 293 of file RONet.cpp.
References RONet::checkSourceAndDestinations(), RandHelper::getRandomFrom(), and RONet::myDestinationEdges.
| ROEdge * RONet::getRandomSource | ( | ) | throw () [inherited] |
Returns a random edge which may be used as a starting point.
If the list of possible source (roads with no predecessor, "mySourceEdges") is empty, it is tried to be built, first.
Definition at line 268 of file RONet.cpp.
References RONet::checkSourceAndDestinations(), RandHelper::getRandomFrom(), and RONet::mySourceEdges.
| const ROEdge * RONet::getRandomSource | ( | ) | const throw () [inherited] |
Returns a random edge which may be used as a starting point.
If the list of possible sources (roads with no predecessor, "mySourceEdges") is empty, it is tried to be built, first.
Definition at line 280 of file RONet.cpp.
References RONet::checkSourceAndDestinations(), RandHelper::getRandomFrom(), and RONet::mySourceEdges.
| RORouteDef* RONet::getRouteDef | ( | const std::string & | name | ) | const throw () [inline, inherited] |
Returns the named route definition.
| [in] | name | The name of the route definition to retrieve |
Check whether a const pointer may be returned
Rename myRoutes to myRouteDefinitions
Definition at line 179 of file RONet.h.
References NamedObjectCont< T >::get(), and RONet::myRoutes.
Referenced by RORDLoader_SUMOBase::closeVehicle().
| SUMOVTypeParameter * RONet::getVehicleTypeSecure | ( | const std::string & | id | ) | throw () [inherited] |
Retrieves the named vehicle type.
If the named vehicle type was not added to the net before, a default vehicle type which consists of the id only is generated, added to the net and returned.
Only if the name is "", 0 is returned.
| [in] | id | The id of the vehicle type to return |
Definition at line 132 of file RONet.cpp.
References SUMOVTypeParameter::id, and SUMOVTypeParameter::onlyReferenced.
Referenced by RORDLoader_SUMOBase::closeVehicle(), and RORDGenerator_ODAmounts::myEndFlowAmountDef().
Definition at line 665 of file RODFNet.cpp.
References myApproachedEdges.
Referenced by computeRoutesFor(), and isDestination().
Definition at line 656 of file RODFNet.cpp.
References myApproachingEdges.
Referenced by isSource().
Definition at line 674 of file RODFNet.cpp.
References myDetectorsOnEdges.
Referenced by RODFDetector::buildDestinationDistribution(), computeRoutesFor(), RODFDetector::computeSplitProbabilities(), isDestination(), isFalseSource(), isSource(), and revalidateFlows().
| bool RODFNet::hasInBetweenDetectorsOnly | ( | ROEdge * | edge, |
| const RODFDetectorCon & | detectors | ||
| ) | const [protected] |
Definition at line 160 of file RODFNet.cpp.
References BETWEEN_DETECTOR, RODFDetectorCon::getDetector(), RODFDetector::getType(), and myDetectorsOnEdges.
Referenced by computeRoutesFor().
| bool RONet::hasRestrictions | ( | ) | const [inherited] |
Definition at line 349 of file RONet.cpp.
References RONet::myHaveRestrictions.
Referenced by computeRoutes().
| bool RODFNet::hasSourceDetector | ( | ROEdge * | edge, |
| const RODFDetectorCon & | detectors | ||
| ) | const [protected] |
Definition at line 176 of file RODFNet.cpp.
References RODFDetectorCon::getDetector(), RODFDetector::getType(), myDetectorsOnEdges, and SOURCE_DETECTOR.
Referenced by computeRoutesFor().
| bool RODFNet::isDestination | ( | const RODFDetector & | det, |
| const RODFDetectorCon & | detectors | ||
| ) | const [protected] |
Definition at line 712 of file RODFNet.cpp.
References getDetectorEdge().
Referenced by computeTypes(), and isDestination().
| bool RODFNet::isDestination | ( | const RODFDetector & | det, |
| ROEdge * | edge, | ||
| std::vector< ROEdge * > & | seen, | ||
| const RODFDetectorCon & | detectors | ||
| ) | const [protected] |
Definition at line 822 of file RODFNet.cpp.
References getAbsPos(), RODFDetectorCon::getDetector(), getDetectorEdge(), RODFDetector::getID(), ROEdge::getSpeed(), hasApproached(), hasDetector(), isDestination(), myAmInHighwayMode, myApproachedEdges, myDetectorEdges, myDetectorsOnEdges, and WRITE_WARNING.
| bool RODFNet::isFalseSource | ( | const RODFDetector & | det, |
| ROEdge * | edge, | ||
| std::vector< ROEdge * > & | seen, | ||
| const RODFDetectorCon & | detectors | ||
| ) | const [protected] |
Definition at line 898 of file RODFNet.cpp.
References BETWEEN_DETECTOR, RODFDetectorCon::getDetector(), getDetectorEdge(), RODFDetector::getID(), ROEdge::getSpeed(), RODFDetector::getType(), hasDetector(), isFalseSource(), myAmInHighwayMode, myApproachedEdges, myDetectorsOnEdges, SINK_DETECTOR, SOURCE_DETECTOR, and WRITE_WARNING.
| bool RODFNet::isFalseSource | ( | const RODFDetector & | det, |
| const RODFDetectorCon & | detectors | ||
| ) | const [protected] |
Definition at line 705 of file RODFNet.cpp.
References getDetectorEdge().
Referenced by computeTypes(), and isFalseSource().
| bool RODFNet::isSource | ( | const RODFDetector & | det, |
| ROEdge * | edge, | ||
| std::vector< ROEdge * > & | seen, | ||
| const RODFDetectorCon & | detectors, | ||
| bool | strict | ||
| ) | const [protected] |
Definition at line 719 of file RODFNet.cpp.
References getAbsPos(), RODFDetectorCon::getDetector(), getDetectorEdge(), RODFDetector::getID(), ROEdge::getSpeed(), hasApproaching(), hasDetector(), isSource(), myAmInHighwayMode, myApproachingEdges, myDetectorEdges, myDetectorsOnEdges, and WRITE_WARNING.
| bool RODFNet::isSource | ( | const RODFDetector & | det, |
| const RODFDetectorCon & | detectors, | ||
| bool | strict | ||
| ) | const [protected] |
Definition at line 697 of file RODFNet.cpp.
References getDetectorEdge().
Referenced by computeTypes(), and isSource().
| void RODFNet::mesoJoin | ( | RODFDetectorCon & | detectors, |
| RODFDetectorFlows & | flows | ||
| ) |
Definition at line 1069 of file RODFNet.cpp.
References buildDetectorEdgeDependencies(), RODFDetectorCon::getDetector(), RODFDetector::getPos(), RODFDetectorCon::mesoJoin(), RODFDetectorFlows::mesoJoin(), myDetectorsOnEdges, and SUMOReal.
| void RONet::openOutput | ( | const std::string & | filename, |
| bool | useAlternatives | ||
| ) | throw (IOError) [inherited] |
Opens the output for computed routes.
If the second parameter is true, a second file for route alternatives will be opened. The route alternatives files is simply the given name with ".alt" appended (before the ".xml"-suffix). If one of the file outputs can not be build, an IOError is thrown
| [in] | filename | The (base) name of the file(s) to create |
| [in] | useAlternatives | Whether a file for writing alternatives shall be created |
Definition at line 102 of file RONet.cpp.
References OutputDevice::getDevice().
Referenced by computeRoutes().
| void RODFNet::removeEmptyDetectors | ( | RODFDetectorCon & | detectors, |
| RODFDetectorFlows & | flows | ||
| ) |
Definition at line 603 of file RODFNet.cpp.
References RODFDetectorCon::getDetectors(), RODFDetectorFlows::knows(), RODFDetectorCon::removeDetector(), RODFDetectorFlows::removeFlow(), and WRITE_MESSAGE.
Referenced by startComputation().
| void RODFNet::reportEmptyDetectors | ( | RODFDetectorCon & | detectors, |
| RODFDetectorFlows & | flows | ||
| ) |
Definition at line 626 of file RODFNet.cpp.
References RODFDetectorCon::getDetectors(), RODFDetectorFlows::knows(), and WRITE_MESSAGE.
Referenced by startComputation().
| void RODFNet::revalidateFlows | ( | const RODFDetector * | detector, |
| RODFDetectorFlows & | flows, | ||
| SUMOTime | startTime, | ||
| SUMOTime | endTime, | ||
| SUMOTime | stepOffset | ||
| ) | [protected] |
Definition at line 441 of file RODFNet.cpp.
References RODFNet::IterationEdge::depth, RODFNet::IterationEdge::edge, getDetectorEdge(), RODFDetectorFlows::getFlowDefs(), RODFEdge::getFlows(), RODFDetector::getID(), hasDetector(), RODFDetectorFlows::knows(), myApproachedEdges, myApproachingEdges, FlowDef::qLKW, FlowDef::qPKW, RODFDetectorFlows::setFlows(), SUMOReal, FlowDef::vLKW, FlowDef::vPKW, and WRITE_WARNING.
| void RODFNet::revalidateFlows | ( | const RODFDetectorCon & | detectors, |
| RODFDetectorFlows & | flows, | ||
| SUMOTime | startTime, | ||
| SUMOTime | endTime, | ||
| SUMOTime | stepOffset | ||
| ) |
Definition at line 589 of file RODFNet.cpp.
References RODFDetectorCon::getDetectors().
Referenced by startComputation().
| SUMOTime RONet::saveAndRemoveRoutesUntil | ( | OptionsCont & | options, |
| SUMOAbstractRouter< ROEdge, ROVehicle > & | router, | ||
| SUMOTime | time | ||
| ) | [inherited] |
Computes routes described by their definitions and saves them.
As long a vehicle with a departure time not larger than the given exists, its route is computed and it is written and removed from the internal container.
| [in] | options | The options used during this process |
| [in] | router | The router to use for routes computation |
| [in] | options | The time until which route definitions shall be processed |
Definition at line 218 of file RONet.cpp.
References RONet::computeRoute(), ROVehicleCont::erase(), OptionsCont::getBool(), ROVehicle::getDepartureTime(), ROVehicle::getID(), OptionsCont::getInt(), ROVehicleCont::getTopVehicle(), RONet::myDiscardedRouteNo, RONet::myReadRouteNo, RONet::myRouteAlternativesOutput, RONet::myRoutesOutput, RONet::myVehicles, RONet::myWrittenRouteNo, ROVehicle::saveAllAsXML(), NamedObjectCont< T >::size(), toString(), and WRITE_MESSAGE.
Referenced by ROLoader::makeSingleStep(), and ROLoader::processAllRoutes().
| void RONet::setRestrictionFound | ( | ) | [inherited] |
Definition at line 355 of file RONet.cpp.
References RONet::myHaveRestrictions.
Referenced by RONetHandler::parseLane().
bool RODFNet::myAmInHighwayMode [private] |
Definition at line 160 of file RODFNet.h.
Referenced by computeRoutesFor(), isDestination(), isFalseSource(), and isSource().
std::map<ROEdge*, std::vector<ROEdge*> > RODFNet::myApproachedEdges [private] |
Map of edge name->list of names of edges approached by this edge.
Definition at line 155 of file RODFNet.h.
Referenced by buildApproachList(), computeRoutesFor(), hasApproached(), isDestination(), isFalseSource(), and revalidateFlows().
std::map<ROEdge*, std::vector<ROEdge*> > RODFNet::myApproachingEdges [private] |
Map of edge name->list of names of this edge approaching edges.
Definition at line 152 of file RODFNet.h.
Referenced by buildApproachList(), hasApproaching(), isSource(), and revalidateFlows().
std::vector<ROEdge*> RONet::myDestinationEdges [mutable, protected, inherited] |
List of destination edges.
Definition at line 321 of file RONet.h.
Referenced by RONet::checkSourceAndDestinations(), and RONet::getRandomDestination().
std::map<std::string, ROEdge*> RODFNet::myDetectorEdges [mutable, private] |
Definition at line 158 of file RODFNet.h.
Referenced by buildDetectorDependencies(), buildDetectorEdgeDependencies(), isDestination(), and isSource().
std::map<ROEdge*, std::vector<std::string> > RODFNet::myDetectorsOnEdges [mutable, private] |
Definition at line 157 of file RODFNet.h.
Referenced by buildDetectorDependencies(), buildDetectorEdgeDependencies(), buildEdgeFlowMap(), buildRoutes(), getDetectorList(), hasDetector(), hasInBetweenDetectorsOnly(), hasSourceDetector(), isDestination(), isFalseSource(), isSource(), and mesoJoin().
std::vector<std::string> RODFNet::myDisallowedEdges [private] |
List of ids of edges that shall not be used.
Definition at line 164 of file RODFNet.h.
Referenced by buildApproachList().
unsigned int RONet::myDiscardedRouteNo [protected, inherited] |
The number of discarded routes.
Definition at line 333 of file RONet.h.
Referenced by RONet::saveAndRemoveRoutesUntil().
NamedObjectCont<ROEdge*> RONet::myEdges [protected, inherited] |
Known edges.
Definition at line 306 of file RONet.h.
Referenced by RONet::checkSourceAndDestinations(), RONet::getEdge(), RONet::getEdgeMap(), RONet::getEdgeNo(), and RONet::~RONet().
bool RONet::myHaveRestrictions [protected, inherited] |
Whether the network contains edges which not all vehicles may pass.
Definition at line 339 of file RONet.h.
Referenced by RONet::hasRestrictions(), and RONet::setRestrictionFound().
size_t RODFNet::myInBetweenNumber [mutable, private] |
Definition at line 161 of file RODFNet.h.
Referenced by computeTypes().
size_t RODFNet::myInvalidNumber [mutable, private] |
Definition at line 161 of file RODFNet.h.
Referenced by computeTypes().
bool RODFNet::myKeepTurnarounds [private] |
Definition at line 167 of file RODFNet.h.
Referenced by buildApproachList().
NamedObjectCont<RONode*> RONet::myNodes [protected, inherited] |
Known nodes.
Definition at line 303 of file RONet.h.
Referenced by RONet::getNode(), and RONet::~RONet().
unsigned int RONet::myReadRouteNo [protected, inherited] |
The number of read routes.
Definition at line 330 of file RONet.h.
Referenced by RONet::saveAndRemoveRoutesUntil().
OutputDevice* RONet::myRouteAlternativesOutput [protected, inherited] |
The file to write the computed route alternatives into.
Definition at line 327 of file RONet.h.
Referenced by RONet::closeOutput(), and RONet::saveAndRemoveRoutesUntil().
NamedObjectCont<RORouteDef*> RONet::myRoutes [protected, inherited] |
Known routes.
Definition at line 312 of file RONet.h.
Referenced by RONet::getRouteDef(), and RONet::~RONet().
OutputDevice* RONet::myRoutesOutput [protected, inherited] |
The file to write the computed routes into.
Definition at line 324 of file RONet.h.
Referenced by RONet::closeOutput(), and RONet::saveAndRemoveRoutesUntil().
size_t RODFNet::mySinkNumber [mutable, private] |
Definition at line 161 of file RODFNet.h.
Referenced by computeTypes().
std::vector<ROEdge*> RONet::mySourceEdges [mutable, protected, inherited] |
List of source edges.
Definition at line 318 of file RONet.h.
Referenced by RONet::checkSourceAndDestinations(), and RONet::getRandomSource().
size_t RODFNet::mySourceNumber [mutable, private] |
Definition at line 161 of file RODFNet.h.
Referenced by computeTypes().
ROVehicleCont RONet::myVehicles [protected, inherited] |
Known vehicles.
Definition at line 315 of file RONet.h.
Referenced by RONet::furtherStored(), RONet::saveAndRemoveRoutesUntil(), and RONet::~RONet().
NamedObjectCont<SUMOVTypeParameter*> RONet::myVehicleTypes [protected, inherited] |
std::set<std::string> RONet::myVehIDs [protected, inherited] |
unsigned int RONet::myWrittenRouteNo [protected, inherited] |
The number of written routes.
Definition at line 336 of file RONet.h.
Referenced by RONet::saveAndRemoveRoutesUntil().