39 #ifdef CHECK_MEMORY_LEAKS
41 #endif // CHECK_MEMORY_LEAKS
55 const std::vector<std::string> edgeNames = ec.
getAllNames();
57 for (std::vector<std::string>::const_iterator i = edgeNames.begin(); i != edgeNames.end(); i++) {
69 JoinedEdgesMap::iterator i =
myMap.find(what);
70 assert(i !=
myMap.end());
77 NBJoinedEdgesMap::JoinedEdgesMap::const_iterator i;
78 for (i = jemap.
myMap.begin(); i != jemap.
myMap.end(); ++i) {
79 os << (*i).first <<
"\t";
81 for (NBJoinedEdgesMap::MappedEdgesVector::const_iterator j = e.begin(); j != e.end(); ++j) {
82 os << (*j) <<
":" << jemap.
myLengths.find(*j)->second <<
"\t";
std::vector< std::string > getAllNames() const
Returns all ids of known edges.
std::map< std::string, SUMOReal > myLengths
~NBJoinedEdgesMap()
Destructor.
Storage for edges, including some functionality operating on multiple edges.
NBEdge * retrieve(const std::string &id, bool retrieveExtracted=false) const
Returns the edge that has the given id.
A structure storing information about which edges were joined.
JoinedEdgesMap myMap
Map of edge names to lists of previous edges the current edge is made of.
std::ostream & operator<<(std::ostream &os, const NBJoinedEdgesMap &jemap)
NBJoinedEdgesMap()
Constructor.
void init(NBEdgeCont &ec)
Initialises the map using the list of edge names.
void appended(const std::string &to, const std::string &what)
Informs the map that two edges have been joined.
std::vector< std::string > MappedEdgesVector
def. of a list of edges that make up an edge
SUMOReal getLength() const
Returns the computed length of the edge.