114 std::map<std::string, NBNode*>::const_iterator
begin()
const {
119 std::map<std::string, NBNode*>::const_iterator
end()
const {
131 void addJoinExclusion(
const std::vector<std::string>& ids,
bool check =
false);
282 int remapIDs(
bool numericaIDs,
bool reservedIDs);
std::string getFreeID()
generates a new node ID
std::set< std::string > myJoinExclusions
set of node ids which should not be joined
NodeCont myNodes
The map of names to nodes.
NBNode * retrieve(const std::string &id) const
Returns the node with the given name.
void joinSimilarEdges(NBDistrictCont &dc, NBEdgeCont &ec, NBTrafficLightLogicCont &tlc)
Joins edges connecting the same nodes.
const std::vector< std::set< std::string > > & getJoinedClusters() const
gets all joined clusters (see doc for myClusters2Join)
void removeSelfLoops(NBDistrictCont &dc, NBEdgeCont &ec, NBTrafficLightLogicCont &tc)
Removes self-loop edges (edges where the source and the destination node are the same) ...
void registerJoinedCluster(const std::set< NBNode *> &cluster)
gets all joined clusters (see doc for myClusters2Join)
std::map< std::string, NBNode * >::const_iterator begin() const
Returns the pointer to the begin of the stored nodes.
void addJoinExclusion(const std::vector< std::string > &ids, bool check=false)
std::map< std::string, NBNode * >::const_iterator end() const
Returns the pointer to the end of the stored nodes.
int removeUnwishedNodes(NBDistrictCont &dc, NBEdgeCont &ec, NBTrafficLightLogicCont &tlc, bool removeGeometryNodes)
Removes "unwished" nodes.
void markAsSplit(const NBNode *node)
mark a node as being created form a split
A container for traffic light definitions and built programs.
void joinTLS(NBTrafficLightLogicCont &tlc, double maxdist)
Builds clusters of tls-controlled junctions and joins the control if possible.
std::vector< std::set< std::string > > myJoinedClusters
sets of node ids which were joined
A RT-tree for efficient storing of SUMO's Named objects.
A container for districts.
int joinLoadedClusters(NBDistrictCont &dc, NBEdgeCont &ec, NBTrafficLightLogicCont &tlc)
Joins loaded junction clusters (see NIXMLNodesHandler)
NamedRTree myRTree
node positions for faster lookup
void guessTLs(OptionsCont &oc, NBTrafficLightLogicCont &tlc)
Guesses which junctions or junction clusters shall be controlled by tls.
void avoidOverlap()
fix overlap
void computeLogics(const NBEdgeCont &ec, OptionsCont &oc)
build the list of outgoing edges and lanes
A class representing a single district.
bool shouldBeTLSControlled(const std::set< NBNode *> &c) const
Returns whethe the given node cluster should be controlled by a tls.
void computeLanes2Lanes()
divides the incoming lanes on outgoing lanes
int size() const
Returns the number of nodes stored in this container.
A point in 2D or 3D with translation and scaling methods.
int myInternalID
The running internal id.
std::pair< NBNode *, double > NodeAndDist
void generateNodeClusters(double maxDist, NodeClusters &into) const
Builds node clusters.
std::map< std::string, NBNode * > NodeCont
Definition of the map of names to nodes.
Storage for edges, including some functionality operating on multiple edges.
void computeNodeShapes(double mismatchThreshold=-1)
Compute the junction shape for this node.
void joinNodeClusters(NodeClusters clusters, NBDistrictCont &dc, NBEdgeCont &ec, NBTrafficLightLogicCont &tlc)
joins the given node clusters
std::set< NBNode * > myExtractedNodes
The extracted nodes which are kept for reference.
int joinJunctions(double maxDist, NBDistrictCont &dc, NBEdgeCont &ec, NBTrafficLightLogicCont &tlc)
Joins junctions that are very close together.
void analyzeCluster(std::set< NBNode *> cluster, std::string &id, Position &pos, bool &hasTLS, TrafficLightType &type)
void rename(NBNode *node, const std::string &newID)
Renames the node. Throws exception if newID already exists.
void setAsTLControlled(NBNode *node, NBTrafficLightLogicCont &tlc, TrafficLightType type, std::string id="")
Sets the given node as being controlled by a tls.
std::vector< std::string > getAllNames() const
get all node names
void addCluster2Join(std::set< std::string > cluster)
add ids of nodes which shall be joined into a single node
int remapIDs(bool numericaIDs, bool reservedIDs)
remap node IDs accoring to options –numerical-ids and –reserved-ids
void removeIsolatedRoads(NBDistrictCont &dc, NBEdgeCont &ec, NBTrafficLightLogicCont &tc)
Removes sequences of edges that are not connected with a junction. Simple roads without junctions som...
std::set< std::string > myJoined
ids found in loaded join clusters used for error checking
A storage for options typed value containers)
std::vector< std::set< NBNode * > > NodeClusters
Definition of a node cluster container.
bool insert(const std::string &id, const Position &position, NBDistrict *district=0)
Inserts a node into the map.
void clear()
deletes all nodes
std::vector< std::set< std::string > > myClusters2Join
loaded sets of node ids to join (cleared after use)
void discardTrafficLights(NBTrafficLightLogicCont &tlc, bool geometryLike, bool guessSignals)
Represents a single node (junction) during network building.
NBNodeCont & operator=(const NBNodeCont &s)
invalidated assignment operator
Static storage of an output device and its base (abstract) implementation.
std::set< const NBNode * > mySplit
nodes that were created when splitting an edge
void printBuiltNodesStatistics() const
Prints statistics about built nodes.
Container for nodes during the netbuilding process.
bool extract(NBNode *node, bool remember=false)
Removes the given node but does not delete it.
bool erase(NBNode *node)
Removes the given node, deleting it.