63 myCalibratorParent(calibratorParent), myRouteID(calibratorParent->generateRouteID()), myColor(
"") {
105 std::vector<std::string>
107 std::vector<std::string> edgeIDs;
108 for (std::vector<GNEEdge*>::const_iterator i =
myEdges.begin(); i !=
myEdges.end(); i++) {
109 edgeIDs.push_back((*i)->getID());
115 const std::vector<GNEEdge*>&
129 if (routeID.empty()) {
142 std::vector<GNEEdge*> edges;
144 for (std::vector<std::string>::const_iterator i = edgeIDs.begin(); i != edgeIDs.end(); i++) {
147 if (edgeTmp != NULL) {
148 edges.push_back(edgeTmp);
183 std::vector<GNEEdge*> edges;
185 for (std::vector<std::string>::const_iterator i = edgeIDs.begin() + 1; i != edgeIDs.end(); i++) {
187 if (retrievedEdge != NULL) {
188 edges.push_back(retrievedEdge);
194 for (std::vector<GNEEdge*>::const_iterator i = edges.begin() + 1; i != edges.end(); i++) {
195 if ((*(i - 1))->getID() == (*i)->getID()) {
200 for (std::vector<GNEEdge*>::const_iterator i = edges.begin() + 1; i != edges.end(); i++) {
202 if (std::find(adyacents.begin(), adyacents.end(), (*i)) == adyacents.end()) {
const std::string & getColor() const
get color of route
GNECalibratorRoute(GNECalibrator *calibratorParent)
default constructor
SumoXMLTag
Numbers representing SUMO-XML - element names.
GNEEdge * retrieveEdge(const std::string &id, bool failHard=true)
get edge by id
std::string checkEdgeRoute(const std::vector< std::string > &edge) const
check if a list of edges is valid to set a route
const std::vector< GNEEdge * > & getGNEOutgoingEdges() const
Returns incoming GNEEdges.
bool setEdges(const std::vector< std::string > &edgeIDs)
set edges of route using IDs
bool routeExists(const std::string &routeID) const
Check if exist a route with these ID.
SumoXMLTag getTag() const
get tag
const std::vector< GNEEdge * > & getEdges() const
get edges
std::vector< GNEEdge * > myEdges
edges of route
std::string myRouteID
route in which this flow is used
const std::string & getRouteID() const
get route ID
begin/end of the description of a route
GNECalibrator * myCalibratorParent
pointer to calibrator parent
std::vector< std::string > getEdgesIDs() const
get IDs of Edges
std::string toString(const T &t, std::streamsize accuracy=gPrecision)
GNEJunction * getGNEJunctionDestiny() const
returns the destination-junction
std::string myColor
color of flow
~GNECalibratorRoute()
destructor
begin/end of the description of an edge
bool setRouteID(std::string routeID)
set route ID
A road/street connecting two junctions (netedit-version)
static bool canParse(const std::string &string)
true if a number of type T can be parsed from string
bool operator==(const GNECalibratorRoute &calibratorRoute) const
overload operator ==
GNEViewNet * getViewNet() const
Returns a pointer to GNEViewNet in which additional element is located.
bool setColor(std::string color="")
set color of route
GNENet * getNet() const
get the net object
static T parse(const std::string &string)
parses a number of type T from string
GNECalibrator * getCalibratorParent() const
get pointer to calibrator parent