![]() |
Eclipse SUMO - Simulation of Urban MObility
|
#include <CHBuilder.h>
Data Structures | |
class | CHConnection |
Forward/backward connection with associated FORWARD cost. More... | |
class | CHInfo |
class | CHInfoComparator |
class | Connection |
Forward/backward connection with associated forward/backward cost. More... | |
struct | Hierarchy |
struct | Shortcut |
Public Types | |
typedef std::pair< const E *, const E * > | ConstEdgePair |
typedef std::map< ConstEdgePair, const E * > | ShortcutVia |
Public Member Functions | |
Hierarchy * | buildContractionHierarchy (SUMOTime time, const V *const vehicle, const SUMOAbstractRouter< E, V > *effortProvider) |
CHBuilder (const std::vector< E * > &edges, bool unbuildIsWarning, const SUMOVehicleClass svc, bool validatePermissions) | |
Constructor. More... | |
virtual | ~CHBuilder () |
Destructor. More... | |
Private Types | |
typedef std::pair< const CHConnection *, const CHConnection * > | CHConnectionPair |
typedef std::vector< CHConnectionPair > | CHConnectionPairs |
typedef std::vector< CHConnection > | CHConnections |
Private Member Functions | |
void | debugPrintQueue (std::vector< CHInfo * > &queue) |
void | disconnect (CHConnections &connections, CHInfo *other) |
remove all connections to/from the given edge (assume it exists only once) More... | |
CHInfo * | getCHInfo (const E *const edge) |
CHBuilder & | operator= (const CHBuilder &s) |
Invalidated assignment operator. More... | |
void | synchronize (CHInfo &info, double time, const V *const vehicle, const SUMOAbstractRouter< E, V > *effortProvider) |
copy connections from the original net (modified destructively during contraction) More... | |
bool | tryUpdateFront (std::vector< CHInfo * > &queue) |
tries to update the priority of the first edge More... | |
Private Attributes | |
std::vector< CHInfo > | myCHInfos |
static vector for lookup More... | |
CHInfoComparator | myCmp |
Comparator for contraction priority. More... | |
const std::vector< E * > & | myEdges |
all edges with numerical ids More... | |
MsgHandler *const | myErrorMsgHandler |
the handler for routing errors More... | |
SPTree< CHInfo, CHConnection > * | mySPTree |
the shortest path tree to use when searching for shortcuts More... | |
const SUMOVehicleClass | mySVC |
the permissions for which the hierarchy was constructed More... | |
int | myUpdateCount |
counters for performance logging More... | |
Definition at line 62 of file CHBuilder.h.
|
private |
Definition at line 221 of file CHBuilder.h.
|
private |
Definition at line 222 of file CHBuilder.h.
|
private |
Definition at line 220 of file CHBuilder.h.
Definition at line 76 of file CHBuilder.h.
typedef std::map<ConstEdgePair, const E*> CHBuilder< E, V >::ShortcutVia |
Definition at line 77 of file CHBuilder.h.
|
inline |
Constructor.
[in] | validatePermissions | Whether a multi-permission hierarchy shall be built If set to false, the net is pruned in synchronize() and the hierarchy is tailored to the svc |
Definition at line 89 of file CHBuilder.h.
References CHBuilder< E, V >::myCHInfos.
|
inline |
Definition at line 108 of file CHBuilder.h.
References CHBuilder< E, V >::CHInfo::approaching, CHBuilder< E, V >::Hierarchy::backwardUplinks, CHBuilder< E, V >::CHConnection::cost, CHBuilder< E, V >::disconnect(), CHBuilder< E, V >::CHInfo::edge, MsgHandler::endProcessMsg(), CHBuilder< E, V >::CHInfo::followers, CHBuilder< E, V >::Hierarchy::forwardUplinks, CHBuilder< E, V >::getCHInfo(), SysUtils::getCurrentMillis(), MsgHandler::getMessageInstance(), CHBuilder< E, V >::myCHInfos, CHBuilder< E, V >::myCmp, CHBuilder< E, V >::mySPTree, CHBuilder< E, V >::mySVC, CHBuilder< E, V >::myUpdateCount, CHBuilder< E, V >::CHConnection::permissions, CHBuilder< E, V >::CHInfo::permissions, CHBuilder< E, V >::CHInfo::priority, PROGRESS_BEGIN_MESSAGE, PROGRESS_DONE_MESSAGE, CHBuilder< E, V >::CHInfo::rank, CHBuilder< E, V >::Hierarchy::shortcuts, CHBuilder< E, V >::CHInfo::shortcuts, STEPS2TIME, SumoVehicleClassStrings, CHBuilder< E, V >::synchronize(), CHBuilder< E, V >::CHConnection::target, time2string(), toString(), CHBuilder< E, V >::tryUpdateFront(), CHBuilder< E, V >::CHInfo::updatePriority(), and WRITE_MESSAGE.
Definition at line 487 of file CHBuilder.h.
References CHBuilder< E, V >::CHInfo::edge, and CHBuilder< E, V >::CHInfo::priority.
Referenced by CHBuilder< E, V >::tryUpdateFront().
|
inlineprivate |
remove all connections to/from the given edge (assume it exists only once)
Definition at line 457 of file CHBuilder.h.
Referenced by CHBuilder< E, V >::buildContractionHierarchy().
Definition at line 417 of file CHBuilder.h.
References CHBuilder< E, V >::myCHInfos.
Referenced by CHBuilder< E, V >::buildContractionHierarchy(), and CHBuilder< E, V >::synchronize().
Invalidated assignment operator.
|
inlineprivate |
copy connections from the original net (modified destructively during contraction)
Definition at line 423 of file CHBuilder.h.
References CHBuilder< E, V >::CHInfo::approaching, CHBuilder< E, V >::CHInfo::edge, CHBuilder< E, V >::CHInfo::followers, CHBuilder< E, V >::getCHInfo(), SUMOAbstractRouter< E, V >::getEffort(), CHBuilder< E, V >::mySPTree, and CHBuilder< E, V >::mySVC.
Referenced by CHBuilder< E, V >::buildContractionHierarchy().
tries to update the priority of the first edge
Definition at line 470 of file CHBuilder.h.
References CHBuilder< E, V >::debugPrintQueue(), CHBuilder< E, V >::CHInfo::edge, CHBuilder< E, V >::myCmp, CHBuilder< E, V >::mySPTree, CHBuilder< E, V >::myUpdateCount, and CHBuilder< E, V >::CHInfo::updatePriority().
Referenced by CHBuilder< E, V >::buildContractionHierarchy().
static vector for lookup
Definition at line 503 of file CHBuilder.h.
Referenced by CHBuilder< E, V >::buildContractionHierarchy(), CHBuilder< E, V >::CHBuilder(), and CHBuilder< E, V >::getCHInfo().
|
private |
Comparator for contraction priority.
Definition at line 506 of file CHBuilder.h.
Referenced by CHBuilder< E, V >::buildContractionHierarchy(), and CHBuilder< E, V >::tryUpdateFront().
all edges with numerical ids
Definition at line 497 of file CHBuilder.h.
|
private |
the handler for routing errors
Definition at line 500 of file CHBuilder.h.
the shortest path tree to use when searching for shortcuts
Definition at line 509 of file CHBuilder.h.
Referenced by CHBuilder< E, V >::buildContractionHierarchy(), CHBuilder< E, V >::synchronize(), CHBuilder< E, V >::tryUpdateFront(), and CHBuilder< E, V >::~CHBuilder().
|
private |
the permissions for which the hierarchy was constructed
Definition at line 512 of file CHBuilder.h.
Referenced by CHBuilder< E, V >::buildContractionHierarchy(), and CHBuilder< E, V >::synchronize().
counters for performance logging
Definition at line 515 of file CHBuilder.h.
Referenced by CHBuilder< E, V >::buildContractionHierarchy(), and CHBuilder< E, V >::tryUpdateFront().