![]() |
Eclipse SUMO - Simulation of Urban MObility
|
#include <SUMOAbstractRouter.h>
Data Structures | |
class | EdgeInfo |
Public Types | |
typedef double(* | Operation) (const E *const, const V *const, double) |
Type of the function that is used to retrieve the edge effort. More... | |
Public Member Functions | |
virtual SUMOAbstractRouter * | clone ()=0 |
virtual bool | compute (const E *from, const E *to, const V *const vehicle, SUMOTime msTime, std::vector< const E * > &into, bool silent=false)=0 |
Builds the route between the given edges using the minimum effort at the given time The definition of the effort depends on the wished routing scheme. More... | |
bool | computeLooped (const E *from, const E *to, const V *const vehicle, SUMOTime msTime, std::vector< const E * > &into, bool silent=false) |
Builds the route between the given edges using the minimum effort at the given time if from == to, return the shortest looped route. More... | |
void | endQuery (int visits) |
double | getEffort (const E *const e, const V *const v, double t) const |
double | getTravelTime (const E *const e, const V *const v, const double t, const double effort) const |
bool | isProhibited (const E *const edge, const V *const vehicle) const |
virtual void | prohibit (const std::vector< E * > &) |
double | recomputeCosts (const std::vector< const E * > &edges, const V *const v, SUMOTime msTime, double *lengthp=nullptr) const |
void | setBulkMode (const bool mode) |
void | startQuery () |
SUMOAbstractRouter (const std::string &type, bool unbuildIsWarning, Operation operation, Operation ttOperation, const bool havePermissions, const bool haveRestrictions) | |
Constructor. More... | |
void | updateViaCost (const E *const prev, const E *const e, const V *const v, double &time, double &effort, double &length) const |
void | updateViaEdgeCost (const E *viaEdge, const V *const v, double &time, double &effort, double &length) const |
virtual | ~SUMOAbstractRouter () |
Destructor. More... | |
Protected Attributes | |
bool | myBulkMode |
whether we are currently operating several route queries in a bulk More... | |
MsgHandler *const | myErrorMsgHandler |
the handler for routing errors More... | |
const bool | myHavePermissions |
whether edge permissions need to be considered More... | |
const bool | myHaveRestrictions |
whether edge restrictions need to be considered More... | |
Operation | myOperation |
The object's operation to perform. More... | |
std::vector< E * > | myProhibited |
Operation | myTTOperation |
The object's operation to perform for travel times. More... | |
Private Member Functions | |
SUMOAbstractRouter & | operator= (const SUMOAbstractRouter &s) |
Invalidated assignment operator. More... | |
Private Attributes | |
long long int | myNumQueries |
long long int | myQueryStartTime |
the time spent querying in milliseconds More... | |
long long int | myQueryTimeSum |
long long int | myQueryVisits |
counters for performance logging More... | |
const std::string | myType |
the type of this router More... | |
The interface for routing the vehicles over the network.
Definition at line 46 of file SUMOAbstractRouter.h.
typedef double(* SUMOAbstractRouter< E, V >::Operation) (const E *const, const V *const, double) |
Type of the function that is used to retrieve the edge effort.
Definition at line 96 of file SUMOAbstractRouter.h.
|
inline |
Constructor.
Definition at line 99 of file SUMOAbstractRouter.h.
|
inlinevirtual |
Destructor.
Definition at line 114 of file SUMOAbstractRouter.h.
|
pure virtual |
|
pure virtual |
Builds the route between the given edges using the minimum effort at the given time The definition of the effort depends on the wished routing scheme.
Implemented in CHRouter< E, V >, AStarRouter< E, V >, DijkstraRouter< E, V >, CHRouterWrapper< E, V >, IntermodalRouter< E, L, N, V >, and PedestrianRouter< E, L, N, V >.
Referenced by NBRailwayTopologyAnalyzer::addBidiEdgesForStops(), TraCIServerAPI_Simulation::commandDistanceRequest(), IntermodalRouter< E, L, N, V >::compute(), SUMOAbstractRouter< E, IntermodalTrip< E, N, V > >::computeLooped(), ROMAAssignments::computePath(), libsumo::Simulation::findRoute(), NBPTLineCont::getCost(), libsumo::Simulation::getDistance2D(), libsumo::Simulation::getDistanceRoad(), LandmarkLookupTable< E, V >::LandmarkLookupTable(), MSTriggeredRerouter::notifyEnter(), RORouteDef::repairCurrentRoute(), MSBaseVehicle::reroute(), MSTriggeredRerouter::rerouteParkingArea(), and MSVehicle::rerouteParkingArea().
|
inline |
Builds the route between the given edges using the minimum effort at the given time if from == to, return the shortest looped route.
Definition at line 130 of file SUMOAbstractRouter.h.
Referenced by MSBaseVehicle::reroute(), and MSTriggeredRerouter::rerouteParkingArea().
|
inline |
Definition at line 225 of file SUMOAbstractRouter.h.
Referenced by DijkstraRouter< E, V >::compute(), AStarRouter< E, V >::compute(), and CHRouter< E, V >::compute().
|
inline |
Definition at line 216 of file SUMOAbstractRouter.h.
Referenced by PedestrianRouter< E, L, N, V >::compute(), IntermodalRouter< E, L, N, V >::compute(), DijkstraRouter< E, V >::compute(), AStarRouter< E, V >::compute(), CHBuilder< E, V >::synchronize(), SUMOAbstractRouter< E, IntermodalTrip< E, N, V > >::updateViaCost(), and SUMOAbstractRouter< E, IntermodalTrip< E, N, V > >::updateViaEdgeCost().
|
inline |
|
inline |
Definition at line 159 of file SUMOAbstractRouter.h.
Referenced by DijkstraRouter< E, V >::compute(), AStarRouter< E, V >::compute(), and SUMOAbstractRouter< E, IntermodalTrip< E, N, V > >::recomputeCosts().
|
private |
Invalidated assignment operator.
|
inlinevirtual |
Reimplemented in AStarRouter< E, V >, DijkstraRouter< E, V >, IntermodalRouter< E, L, N, V >, and PedestrianRouter< E, L, N, V >.
Definition at line 163 of file SUMOAbstractRouter.h.
Referenced by MSRoutingEngine::getRouterTT(), IntermodalRouter< E, L, N, V >::prohibit(), and MSRoutingEngine::reroute().
|
inline |
Definition at line 195 of file SUMOAbstractRouter.h.
Referenced by RORouteDef::addAlternative(), AStarRouter< E, V >::compute(), SUMOAbstractRouter< E, IntermodalTrip< E, N, V > >::computeLooped(), ROMAAssignments::computePath(), computeRoutes(), libsumo::Simulation::findRoute(), NBPTLineCont::getCost(), LandmarkLookupTable< E, V >::LandmarkLookupTable(), MSTriggeredRerouter::notifyEnter(), MSBaseVehicle::reroute(), MSTriggeredRerouter::rerouteParkingArea(), MSVehicle::rerouteParkingArea(), and ROMAAssignments::sue().
|
inline |
Definition at line 230 of file SUMOAbstractRouter.h.
Referenced by ROMAAssignments::incremental().
|
inline |
Definition at line 220 of file SUMOAbstractRouter.h.
Referenced by DijkstraRouter< E, V >::compute(), AStarRouter< E, V >::compute(), and CHRouter< E, V >::compute().
|
inline |
Definition at line 179 of file SUMOAbstractRouter.h.
Referenced by IntermodalRouter< E, L, N, V >::compute(), and SUMOAbstractRouter< E, IntermodalTrip< E, N, V > >::recomputeCosts().
|
inline |
Definition at line 169 of file SUMOAbstractRouter.h.
Referenced by DijkstraRouter< E, V >::compute(), AStarRouter< E, V >::compute(), and SUMOAbstractRouter< E, IntermodalTrip< E, N, V > >::updateViaCost().
|
protected |
whether we are currently operating several route queries in a bulk
Definition at line 245 of file SUMOAbstractRouter.h.
Referenced by DijkstraRouter< E, V >::compute(), AStarRouter< E, V >::compute(), and SUMOAbstractRouter< E, IntermodalTrip< E, N, V > >::setBulkMode().
|
protected |
the handler for routing errors
Definition at line 236 of file SUMOAbstractRouter.h.
Referenced by DijkstraRouter< E, V >::clone(), AStarRouter< E, V >::clone(), CHRouter< E, V >::clone(), DijkstraRouter< E, V >::compute(), AStarRouter< E, V >::compute(), CHRouter< E, V >::compute(), and SUMOAbstractRouter< E, IntermodalTrip< E, N, V > >::computeLooped().
|
protected |
whether edge permissions need to be considered
Definition at line 248 of file SUMOAbstractRouter.h.
Referenced by DijkstraRouter< E, V >::clone(), CHRouter< E, V >::clone(), and SUMOAbstractRouter< E, IntermodalTrip< E, N, V > >::isProhibited().
|
protected |
whether edge restrictions need to be considered
Definition at line 251 of file SUMOAbstractRouter.h.
Referenced by DijkstraRouter< E, V >::clone(), CHRouter< E, V >::clone(), and SUMOAbstractRouter< E, IntermodalTrip< E, N, V > >::isProhibited().
|
private |
Definition at line 261 of file SUMOAbstractRouter.h.
Referenced by SUMOAbstractRouter< E, IntermodalTrip< E, N, V > >::startQuery(), and SUMOAbstractRouter< E, IntermodalTrip< E, N, V > >::~SUMOAbstractRouter().
|
protected |
The object's operation to perform.
Definition at line 239 of file SUMOAbstractRouter.h.
Referenced by CHRouterWrapper< E, V >::clone(), DijkstraRouter< E, V >::clone(), AStarRouter< E, V >::clone(), CHRouter< E, V >::clone(), and SUMOAbstractRouter< E, IntermodalTrip< E, N, V > >::getEffort().
|
protected |
Definition at line 253 of file SUMOAbstractRouter.h.
Referenced by DijkstraRouter< E, V >::prohibit(), and AStarRouter< E, V >::prohibit().
|
private |
the time spent querying in milliseconds
Definition at line 263 of file SUMOAbstractRouter.h.
Referenced by SUMOAbstractRouter< E, IntermodalTrip< E, N, V > >::endQuery(), and SUMOAbstractRouter< E, IntermodalTrip< E, N, V > >::startQuery().
|
private |
Definition at line 264 of file SUMOAbstractRouter.h.
Referenced by SUMOAbstractRouter< E, IntermodalTrip< E, N, V > >::endQuery(), and SUMOAbstractRouter< E, IntermodalTrip< E, N, V > >::~SUMOAbstractRouter().
|
private |
counters for performance logging
Definition at line 260 of file SUMOAbstractRouter.h.
Referenced by SUMOAbstractRouter< E, IntermodalTrip< E, N, V > >::endQuery(), and SUMOAbstractRouter< E, IntermodalTrip< E, N, V > >::~SUMOAbstractRouter().
|
protected |
The object's operation to perform for travel times.
Definition at line 242 of file SUMOAbstractRouter.h.
Referenced by DijkstraRouter< E, V >::clone(), and SUMOAbstractRouter< E, IntermodalTrip< E, N, V > >::getTravelTime().
|
private |
the type of this router
Definition at line 257 of file SUMOAbstractRouter.h.
Referenced by SUMOAbstractRouter< E, IntermodalTrip< E, N, V > >::~SUMOAbstractRouter().