743 bool parsedOk =
true;
745 const std::string
id = attrs.
get<std::string>(
SUMO_ATTR_ID,
"", parsedOk);
746 const std::string laneId = attrs.
get<std::string>(
SUMO_ATTR_LANE,
id.c_str(), parsedOk);
751 const std::vector<std::string> lines = attrs.
getOpt<std::vector<std::string> >(
SUMO_ATTR_LINES,
id.c_str(), parsedOk, std::vector<std::string>());
778 bool parsedOk =
true;
780 const std::string
id = attrs.
get<std::string>(
SUMO_ATTR_ID,
"", parsedOk);
781 const std::string laneId = attrs.
get<std::string>(
SUMO_ATTR_LANE,
id.c_str(), parsedOk);
786 const std::vector<std::string> lines = attrs.
getOpt<std::vector<std::string> >(
SUMO_ATTR_LINES,
id.c_str(), parsedOk, std::vector<std::string>());
813 bool parsedOk =
true;
838 bool parsedOk =
true;
840 const std::string
id = attrs.
get<std::string>(
SUMO_ATTR_ID,
"", parsedOk);
841 const std::string laneId = attrs.
get<std::string>(
SUMO_ATTR_LANE,
id.c_str(), parsedOk);
846 const std::vector<std::string> lines = attrs.
getOpt<std::vector<std::string> >(
SUMO_ATTR_LINES,
id.c_str(), parsedOk, std::vector<std::string>());
873 bool parsedOk =
true;
875 const std::string
id = attrs.
get<std::string>(
SUMO_ATTR_ID,
"", parsedOk);
876 const std::string laneId = attrs.
get<std::string>(
SUMO_ATTR_LANE,
id.c_str(), parsedOk);
881 const std::vector<std::string> lines = attrs.
getOpt<std::vector<std::string> >(
SUMO_ATTR_LINES,
id.c_str(), parsedOk, std::vector<std::string>());
892 if ((chargeType !=
"normal") && (chargeType !=
"electric") && (chargeType !=
"fuel")) {
893 writeError(
TLF(
"Invalid charge type '%' defined in chargingStation '%'.", chargeType,
id));
922 bool parsedOk =
true;
924 const std::string
id = attrs.
get<std::string>(
SUMO_ATTR_ID,
"", parsedOk);
925 const std::string laneId = attrs.
get<std::string>(
SUMO_ATTR_LANE,
id.c_str(), parsedOk);
931 const std::vector<std::string> badges = attrs.
getOpt<std::vector<std::string> >(
SUMO_ATTR_ACCEPTED_BADGES,
id.c_str(), parsedOk, std::vector<std::string>());
966 bool parsedOk =
true;
999 bool parsedOk =
true;
1001 const std::string
id = attrs.
get<std::string>(
SUMO_ATTR_ID,
"", parsedOk);
1002 const std::string laneId = attrs.
get<std::string>(
SUMO_ATTR_LANE,
id.c_str(), parsedOk);
1005 const std::string file = attrs.
get<std::string>(
SUMO_ATTR_FILE,
id.c_str(), parsedOk);
1008 const std::vector<std::string> vehicleTypes = attrs.
getOpt<std::vector<std::string> >(
SUMO_ATTR_VTYPES,
id.c_str(), parsedOk, std::vector<std::string>());
1009 const std::vector<std::string> nextEdges = attrs.
getOpt<std::vector<std::string> >(
SUMO_ATTR_NEXT_EDGES,
id.c_str(), parsedOk, std::vector<std::string>());
1034 bool parsedOk =
true;
1040 writeError(
TL(
"'pos', 'endPos' and 'length' cannot be defined together in a single lane area detector."));
1042 writeError(
TL(
"A single lane area detector requires two parameters of those 'pos', 'endPos' and 'length'."));
1045 const std::string
id = attrs.
get<std::string>(
SUMO_ATTR_ID,
"", parsedOk);
1046 const std::string file = attrs.
get<std::string>(
SUMO_ATTR_FILE,
id.c_str(), parsedOk);
1048 const std::string laneId = attrs.
getOpt<std::string>(
SUMO_ATTR_LANE,
id.c_str(), parsedOk,
"");
1049 const std::vector<std::string> laneIds = attrs.
getOpt<std::vector<std::string> >(
SUMO_ATTR_LANES,
id.c_str(), parsedOk, std::vector<std::string>());
1055 const std::string trafficLight = attrs.
getOpt<std::string>(
SUMO_ATTR_TLID,
id.c_str(), parsedOk,
"");
1060 const std::vector<std::string> vehicleTypes = attrs.
getOpt<std::vector<std::string> >(
SUMO_ATTR_VTYPES,
id.c_str(), parsedOk, std::vector<std::string>());
1061 const std::vector<std::string> nextEdges = attrs.
getOpt<std::vector<std::string> >(
SUMO_ATTR_NEXT_EDGES,
id.c_str(), parsedOk, std::vector<std::string>());
1072 if (positionDef == 0) {
1075 }
else if (endPosDef == 0) {
1078 }
else if (lengthDef == 0) {
1109 bool parsedOk =
true;
1111 const std::string
id = attrs.
get<std::string>(
SUMO_ATTR_ID,
"", parsedOk);
1112 const std::string file = attrs.
get<std::string>(
SUMO_ATTR_FILE,
id.c_str(), parsedOk);
1116 const std::vector<std::string> vehicleTypes = attrs.
getOpt<std::vector<std::string> >(
SUMO_ATTR_VTYPES,
id.c_str(), parsedOk, std::vector<std::string>());
1117 const std::vector<std::string> nextEdges = attrs.
getOpt<std::vector<std::string> >(
SUMO_ATTR_NEXT_EDGES,
id.c_str(), parsedOk, std::vector<std::string>());
1148 bool parsedOk =
true;
1150 const std::string laneId = attrs.
get<std::string>(
SUMO_ATTR_LANE,
"", parsedOk);
1171 bool parsedOk =
true;
1173 const std::string laneId = attrs.
get<std::string>(
SUMO_ATTR_LANE,
"", parsedOk);
1194 bool parsedOk =
true;
1196 const std::string
id = attrs.
get<std::string>(
SUMO_ATTR_ID,
"", parsedOk);
1197 const std::string laneId = attrs.
get<std::string>(
SUMO_ATTR_LANE,
id.c_str(), parsedOk);
1199 const std::string file = attrs.
get<std::string>(
SUMO_ATTR_FILE,
id.c_str(), parsedOk);
1202 const std::vector<std::string> vehicleTypes = attrs.
getOpt<std::vector<std::string> >(
SUMO_ATTR_VTYPES,
id.c_str(), parsedOk, std::vector<std::string>());
1203 const std::vector<std::string> nextEdges = attrs.
getOpt<std::vector<std::string> >(
SUMO_ATTR_NEXT_EDGES,
id.c_str(), parsedOk, std::vector<std::string>());
1227 bool parsedOk =
true;
1229 const std::string
id = attrs.
get<std::string>(
SUMO_ATTR_ID,
"", parsedOk);
1234 const std::vector<std::string> edges = attrs.
getOpt<std::vector<std::string> >(
SUMO_ATTR_EDGES,
id.c_str(), parsedOk, std::vector<std::string>());
1256 bool parsedOk =
true;
1258 const std::string edgeID = attrs.
get<std::string>(
SUMO_ATTR_ID,
"", parsedOk);
1276 bool parsedOk =
true;
1278 const std::string edgeID = attrs.
get<std::string>(
SUMO_ATTR_ID,
"", parsedOk);
1296 bool parsedOk =
true;
1298 const std::string
id = attrs.
get<std::string>(
SUMO_ATTR_ID,
"", parsedOk);
1299 const std::vector<std::string> lanes = attrs.
get<std::vector<std::string> >(
SUMO_ATTR_LANES,
id.c_str(), parsedOk);
1303 const std::vector<std::string> vehicleTypes = attrs.
getOpt<std::vector<std::string> >(
SUMO_ATTR_VTYPES,
id.c_str(), parsedOk, std::vector<std::string>());
1321 bool parsedOk =
true;
1342 bool parsedOk =
true;
1346 writeError(
TL(
"Calibrators need either an edge or a lane"));
1350 const std::string
id = attrs.
get<std::string>(
SUMO_ATTR_ID,
"", parsedOk);
1361 const std::vector<std::string> vehicleTypes = attrs.
getOpt<std::vector<std::string> >(
SUMO_ATTR_VTYPES,
id.c_str(), parsedOk, std::vector<std::string>());
1387 bool parsedOk =
true;
1393 writeError(
TL(
"CalibratorFlows need either the attribute vehsPerHour or speed or type (or any combination of these)"));
1397 if (flowParameter) {
1416 delete flowParameter;
1426 bool parsedOk =
true;
1428 const std::string
id = attrs.
get<std::string>(
SUMO_ATTR_ID,
"", parsedOk);
1429 const std::vector<std::string> edges = attrs.
get<std::vector<std::string> >(
SUMO_ATTR_EDGES,
id.c_str(), parsedOk);
1435 const std::vector<std::string> vehicleTypes = attrs.
getOpt<std::vector<std::string> >(
SUMO_ATTR_VTYPES,
id.c_str(), parsedOk, std::vector<std::string>());
1459 bool parsedOk =
true;
1479 bool parsedOk =
true;
1481 const std::string laneID = attrs.
get<std::string>(
SUMO_ATTR_ID,
"", parsedOk);
1484 const std::string allow = attrs.
getOpt<std::string>(
SUMO_ATTR_ALLOW,
"", parsedOk, !disallow.size() ?
"authority" :
"");
1502 bool parsedOk =
true;
1504 const std::string edgeID = attrs.
get<std::string>(
SUMO_ATTR_ID,
"", parsedOk);
1507 const std::string allow = attrs.
getOpt<std::string>(
SUMO_ATTR_ALLOW,
"", parsedOk, !disallow.size() ?
"authority" :
"");
1525 bool parsedOk =
true;
1527 const std::string edgeID = attrs.
get<std::string>(
SUMO_ATTR_ID,
"", parsedOk);
1533 if (probability < 0) {
1549 bool parsedOk =
true;
1551 const std::string parkingAreaID = attrs.
get<std::string>(
SUMO_ATTR_ID,
"", parsedOk);
1559 if (probability < 0) {
1576 bool parsedOk =
true;
1578 const std::string routeID = attrs.
get<std::string>(
SUMO_ATTR_ID,
"", parsedOk);
1584 if (probability < 0) {
1600 bool parsedOk =
true;
1602 const std::string
id = attrs.
get<std::string>(
SUMO_ATTR_ID,
"", parsedOk);
1603 const std::string edge = attrs.
get<std::string>(
SUMO_ATTR_EDGE,
id.c_str(), parsedOk);
1604 const std::string file = attrs.
get<std::string>(
SUMO_ATTR_FILE,
id.c_str(), parsedOk);
1609 const std::vector<std::string> vehicleTypes = attrs.
getOpt<std::vector<std::string> >(
SUMO_ATTR_VTYPES,
id.c_str(), parsedOk, std::vector<std::string>());
1629 bool parsedOk =
true;
1631 const std::string edgeID = attrs.
get<std::string>(
SUMO_ATTR_ID,
"", parsedOk);
1635 const std::string name = attrs.
getOpt<std::string>(
SUMO_ATTR_NAME, edgeID.c_str(), parsedOk,
"");
1652 bool parsedOk =
true;
1654 const std::string
id = attrs.
get<std::string>(
SUMO_ATTR_ID,
"", parsedOk);
1675 bool parsedOk =
true;
1677 const std::string
id = attrs.
get<std::string>(
SUMO_ATTR_ID,
"", parsedOk);
1679 const std::vector<std::string> laneIDs = attrs.
get<std::vector<std::string> >(
SUMO_ATTR_LANES,
id.c_str(), parsedOk);
1704 bool parsedOk =
true;
1706 const std::string
id = attrs.
get<std::string>(
SUMO_ATTR_ID,
"", parsedOk);
1730 bool parsedOk =
true;
1732 const std::string
id = attrs.
get<std::string>(
SUMO_ATTR_ID,
"", parsedOk);
1769 bool parsedOk =
true;
1773 writeError(
TL(
"X and Y must be be defined together in POIs"));
1779 writeError(
TL(
"lane and position must be defined together in POIs"));
1785 writeError(
TL(
"lon and lat must be be defined together in POIs"));
1789 const std::string
id = attrs.
get<std::string>(
SUMO_ATTR_ID,
"", parsedOk);
1851 bool parsedOk =
true;
1853 const std::string
id = attrs.
get<std::string>(
SUMO_ATTR_ID,
"", parsedOk);
1872 bool parsedOk =
true;
1874 const std::string
id = attrs.
get<std::string>(
SUMO_ATTR_ID,
"", parsedOk);
1893 bool parsedOk =
true;
1895 const std::string key = attrs.
get<std::string>(
SUMO_ATTR_KEY,
nullptr, parsedOk);
1899 if (SumoBaseObjectParent ==
nullptr) {
1900 writeError(
TL(
"Parameters must be defined within an object."));
1902 writeError(
TL(
"Parameters cannot be defined in the additional file's root."));
1904 writeError(
TL(
"Parameters cannot be defined within another parameter."));
1905 }
else if (parsedOk) {
1907 const std::string parentTagStr =
toString(SumoBaseObjectParent->getTag());
1912 WRITE_WARNINGF(
TL(
"Error parsing key from % generic parameter. Key cannot be empty."), parentTagStr);
1914 WRITE_WARNINGF(
TL(
"Error parsing key from % generic parameter. Key contains invalid characters."), parentTagStr);
1916 WRITE_DEBUG(
"Inserting generic parameter '" + key +
"|" + value +
"' into " + parentTagStr);
1918 SumoBaseObjectParent->addParameter(key, value);
1928 if ((parent !=
nullptr) &&
1929 (parentTags.size() > 0) &&
1930 (std::find(parentTags.begin(), parentTags.end(), parent->
getTag()) == parentTags.end())) {
#define WRITE_WARNINGF(...)
#define WRITE_WARNING(msg)
#define SUMOTime_MAX_PERIOD
SVCPermissions parseVehicleClasses(const std::string &allowedS)
Parses the given definition of allowed vehicle classes into the given containers Deprecated classes g...
const long long int VEHPARS_VPH_SET
const long long int VEHPARS_CALIBRATORSPEED_SET
SumoXMLTag
Numbers representing SUMO-XML - element names.
@ SUMO_TAG_TRACTION_SUBSTATION
A traction substation.
@ SUMO_TAG_INTERVAL
an aggreagated-output interval
@ SUMO_TAG_CLOSING_REROUTE
reroute of type closing
@ SUMO_TAG_REROUTER
A rerouter.
@ SUMO_TAG_ROUTEPROBE
a routeprobe detector
@ SUMO_TAG_TAZ
a traffic assignment zone
@ SUMO_TAG_E2DETECTOR
an e2 detector
@ SUMO_TAG_CHARGING_STATION
A Charging Station.
@ SUMO_TAG_ACCESS
An access point for a train stop.
@ SUMO_TAG_CONTAINER_STOP
A container stop.
@ SUMO_TAG_PARKING_AREA_REROUTE
entry for an alternative parking zone
@ SUMO_TAG_ROOTFILE
root file
@ SUMO_TAG_TAZSINK
a sink within a district (connection road)
@ SUMO_TAG_BUS_STOP
A bus stop.
@ SUMO_TAG_POI
begin/end of the description of a Point of interest
@ SUMO_TAG_STEP
trigger: a step description
@ SUMO_TAG_OVERHEAD_WIRE_CLAMP
An overhead wire clamp (connection of wires in opposite directions)
@ SUMO_TAG_FLOW
a flow definition using from and to edges or a route
@ SUMO_TAG_PARKING_AREA
A parking area.
@ SUMO_TAG_ROUTE_PROB_REROUTE
probability of route of a reroute
@ GNE_TAG_CALIBRATOR_LANE
A calibrator placed over lane.
@ SUMO_TAG_DET_ENTRY
an e3 entry point
@ SUMO_TAG_PARKING_SPACE
A parking space for a single vehicle within a parking area.
@ SUMO_TAG_POLY
begin/end of the description of a polygon
@ SUMO_TAG_OVERHEAD_WIRE_SECTION
An overhead wire section.
@ SUMO_TAG_TRAIN_STOP
A train stop (alias for bus stop)
@ SUMO_TAG_INSTANT_INDUCTION_LOOP
An instantenous induction loop.
@ SUMO_TAG_DEST_PROB_REROUTE
probability of destination of a reroute
@ SUMO_TAG_PARAM
parameter associated to a certain key
@ SUMO_TAG_E1DETECTOR
an e1 detector
@ GNE_TAG_JPS_OBSTACLE
polygon used for draw juPedSim obstacles
@ SUMO_TAG_DET_EXIT
an e3 exit point
@ SUMO_TAG_VAPORIZER
vaporizer of vehicles
@ SUMO_TAG_LANE_AREA_DETECTOR
alternative tag for e2 detector
@ SUMO_TAG_TAZSOURCE
a source within a district (connection road)
@ SUMO_TAG_CLOSING_LANE_REROUTE
lane of a reroute of type closing
@ SUMO_TAG_INDUCTION_LOOP
alternative tag for e1 detector
@ GNE_TAG_JPS_WALKABLEAREA
polygon used for draw juPedSim walkable areas
@ SUMO_TAG_CALIBRATOR
A calibrator placed over edge.
@ SUMO_TAG_ENTRY_EXIT_DETECTOR
alternative tag for e3 detector
@ SUMO_TAG_E3DETECTOR
an e3 detector
@ SUMO_TAG_VSS
A variable speed sign.
@ SUMO_ATTR_EXPECT_ARRIVAL
@ SUMO_ATTR_ACCEPTED_BADGES
@ SUMO_ATTR_SUBSTATIONID
id of a traction substation substation
@ SUMO_ATTR_JAM_DIST_THRESHOLD
@ SUMO_ATTR_CHARGETYPE
Charge type (fuel or electric)
@ SUMO_ATTR_PARKING_LENGTH
@ SUMO_ATTR_VOLTAGE
voltage of the traction substation [V]
@ SUMO_ATTR_BEGIN
weights: time range begin
@ SUMO_ATTR_EDGES
the edges of a route
@ SUMO_ATTR_OVERHEAD_WIRE_FORBIDDEN
forbidden lanes for overhead wire segment
@ SUMO_ATTR_HALTING_TIME_THRESHOLD
@ SUMO_ATTR_OVERHEAD_WIRECLAMP_END
id of the overhead wire, to the end of which the overhead wire clamp is connected
@ SUMO_ATTR_SHAPE
edge: the shape in xml-definition
@ SUMO_ATTR_OVERHEAD_WIRECLAMP_LANESTART
id of the overhead wire lane, to the start of which the overhead wire clamp is connected
@ SUMO_ATTR_CHARGEINTRANSIT
Allow/disallow charge in transit in Charging Stations.
@ SUMO_ATTR_OVERHEAD_WIRECLAMP_START
id of the overhead wire, to the start of which the overhead wire clamp is connected
@ SUMO_ATTR_CONTAINER_CAPACITY
@ SUMO_ATTR_FILL
Fill the polygon.
@ SUMO_ATTR_LAYER
A layer number.
@ SUMO_ATTR_HALTING_SPEED_THRESHOLD
@ SUMO_ATTR_END
weights: time range end
@ SUMO_ATTR_ROADSIDE_CAPACITY
@ SUMO_ATTR_CURRENTLIMIT
current limit of the traction substation [A]
@ SUMO_ATTR_TLID
link,node: the traffic light id responsible for this link
@ SUMO_ATTR_SHOW_DETECTOR
@ SUMO_ATTR_CHARGINGPOWER
@ SUMO_ATTR_COLOR
A color information.
@ SUMO_ATTR_EFFICIENCY
Eficiency of the charge in Charging Stations.
@ SUMO_ATTR_PERSON_CAPACITY
@ SUMO_ATTR_CHARGEDELAY
Delay in the charge of charging stations (different of waiting time)
@ SUMO_ATTR_TIME
trigger: the time of the step
@ SUMO_ATTR_OVERHEAD_WIRECLAMP_LANEEND
id of the overhead wire lane, to the end of which the overhead wire clamp is connected
@ SUMO_ATTR_DETECT_PERSONS
const double INVALID_DOUBLE
invalid double
std::string toString(const T &t, std::streamsize accuracy=gPrecision)
virtual void buildDestProbReroute(const CommonXMLStructure::SumoBaseObject *sumoBaseObject, const std::string &newEdgeDestinationID, const double probability)=0
builds a dest prob reroute
void parseE1InstantAttributes(const SUMOSAXAttributes &attrs)
parse E1 instant attributes
void parseCalibratorAttributes(const SUMOSAXAttributes &attrs)
parse calibrator attributes
void parseChargingStationAttributes(const SUMOSAXAttributes &attrs)
parse chargingStation attributes
virtual void buildSingleLaneDetectorE2(const CommonXMLStructure::SumoBaseObject *sumoBaseObject, const std::string &id, const std::string &laneID, const double pos, const double length, const SUMOTime period, const std::string &trafficLight, const std::string &filename, const std::vector< std::string > &vehicleTypes, const std::vector< std::string > &nextEdges, const std::string &detectPersons, const std::string &name, const SUMOTime timeThreshold, const double speedThreshold, const double jamThreshold, const bool friendlyPos, const bool show, const Parameterised::Map ¶meters)=0
Builds a single-lane Area Detector (E2)
virtual void buildRouteProbReroute(const CommonXMLStructure::SumoBaseObject *sumoBaseObject, const std::string &newRouteID, const double probability)=0
builds a route prob reroute
virtual void buildVariableSpeedSign(const CommonXMLStructure::SumoBaseObject *sumoBaseObject, const std::string &id, const Position &pos, const std::vector< std::string > &laneIDs, const std::string &name, const std::vector< std::string > &vTypes, const Parameterised::Map ¶meters)=0
Builds a VariableSpeedSign (lane speed additional)
bool checkDetectPersons(const SumoXMLTag currentTag, const std::string &id, const std::string &detectPersons)
check detect persons
virtual void buildTrainStop(const CommonXMLStructure::SumoBaseObject *sumoBaseObject, const std::string &id, const std::string &laneID, const double startPos, const double endPos, const std::string &name, const std::vector< std::string > &lines, const int personCapacity, const double parkingLength, const RGBColor &color, const bool friendlyPosition, const Parameterised::Map ¶meters)=0
Builds a train stop.
void parseSumoBaseObject(CommonXMLStructure::SumoBaseObject *obj)
parse SumoBaseObject (it's called recursivelly)
virtual void buildEdgeCalibrator(const CommonXMLStructure::SumoBaseObject *sumoBaseObject, const std::string &id, const std::string &edgeID, const double pos, const std::string &name, const std::string &outfile, const SUMOTime period, const std::string &routeprobe, const double jamThreshold, const std::vector< std::string > &vTypes, const Parameterised::Map ¶meters)=0
builds a microscopic calibrator over an edge
virtual void buildRerouterInterval(const CommonXMLStructure::SumoBaseObject *sumoBaseObject, const SUMOTime begin, const SUMOTime end)=0
builds a rerouter interval
virtual void buildParkingSpace(const CommonXMLStructure::SumoBaseObject *sumoBaseObject, const double x, const double y, const double z, const std::string &name, const std::string &width, const std::string &length, const std::string &angle, const double slope, const Parameterised::Map ¶meters)=0
Builds a Parking Space.
void parseRouteProbRerouteAttributes(const SUMOSAXAttributes &attrs)
parse route prob reroute attributes
virtual void buildRerouter(const CommonXMLStructure::SumoBaseObject *sumoBaseObject, const std::string &id, const Position &pos, const std::vector< std::string > &edgeIDs, const double prob, const std::string &name, const bool off, const bool optional, const SUMOTime timeThreshold, const std::vector< std::string > &vTypes, const Parameterised::Map ¶meters)=0
builds a rerouter
void parseJpsWalkableAreaAttributes(const SUMOSAXAttributes &attrs)
parse juPedSim walkable area attributes
void parseCalibratorFlowAttributes(const SUMOSAXAttributes &attrs)
parse calibrator flow attributes
void parseParkingAreaRerouteAttributes(const SUMOSAXAttributes &attrs)
parse parking area reroute attributes
void parseTAZAttributes(const SUMOSAXAttributes &attrs)
parse TAZ attributes
AdditionalHandler()
Constructor.
virtual void buildPOILane(const CommonXMLStructure::SumoBaseObject *sumoBaseObject, const std::string &id, const std::string &type, const RGBColor &color, const std::string &laneID, const double posOverLane, const bool friendlyPosition, const double posLat, const std::string &icon, const double layer, const double angle, const std::string &imgFile, const bool relativePath, const double width, const double height, const std::string &name, const Parameterised::Map ¶meters)=0
Builds a POI over lane using the given values.
virtual void buildLaneCalibrator(const CommonXMLStructure::SumoBaseObject *sumoBaseObject, const std::string &id, const std::string &laneID, const double pos, const std::string &name, const std::string &outfile, const SUMOTime period, const std::string &routeprobe, const double jamThreshold, const std::vector< std::string > &vTypes, const Parameterised::Map ¶meters)=0
builds a microscopic calibrator over a lane
void checkParent(const SumoXMLTag currentTag, const std::vector< SumoXMLTag > &parentTags, bool &ok)
check parents
void parseOverheadWire(const SUMOSAXAttributes &attrs)
parse overhead wire segment
CommonXMLStructure myCommonXMLStructure
common XML Structure
virtual void buildOverheadWireClamp(const CommonXMLStructure::SumoBaseObject *sumoBaseObject, const std::string &id, const std::string &overheadWireIDStartClamp, const std::string &laneIDStartClamp, const std::string &overheadWireIDEndClamp, const std::string &laneIDEndClamp, const Parameterised::Map ¶meters)=0
build overhead wire clamp
void parseTractionSubstation(const SUMOSAXAttributes &attrs)
parse traction substation
void parseE3Attributes(const SUMOSAXAttributes &attrs)
parse E3 attributes
void parseE2Attributes(const SUMOSAXAttributes &attrs)
parse E2 attributes
void parseTAZSinkAttributes(const SUMOSAXAttributes &attrs)
parse TAZ sink attributes
void parseOverheadWireClamp(const SUMOSAXAttributes &attrs)
parse overhead wire clamp
void writeError(const std::string &error)
write error and enable error creating element
bool beginParseAttributes(SumoXMLTag tag, const SUMOSAXAttributes &attrs)
begin parse attributes
void parseTrainStopAttributes(const SUMOSAXAttributes &attrs)
parse trainStop attributes
virtual void buildVariableSpeedSignStep(const CommonXMLStructure::SumoBaseObject *sumoBaseObject, const SUMOTime time, const std::string &speed)=0
Builds a VariableSpeedSign Step.
virtual void buildDetectorEntry(const CommonXMLStructure::SumoBaseObject *sumoBaseObject, const std::string &laneID, const double pos, const bool friendlyPos, const Parameterised::Map ¶meters)=0
Builds a entry detector (E3)
void parsePOIAttributes(const SUMOSAXAttributes &attrs)
parse POI attributes
bool myErrorCreatingElement
flag for check if a element wasn't created
void endParseAttributes()
end parse attributes
virtual void buildE1Detector(const CommonXMLStructure::SumoBaseObject *sumoBaseObject, const std::string &id, const std::string &laneID, const double position, const SUMOTime period, const std::string &file, const std::vector< std::string > &vehicleTypes, const std::vector< std::string > &nextEdges, const std::string &detectPersons, const std::string &name, const bool friendlyPos, const Parameterised::Map ¶meters)=0
Builds a induction loop detector (E1)
virtual void buildDetectorE3(const CommonXMLStructure::SumoBaseObject *sumoBaseObject, const std::string &id, const Position &pos, const SUMOTime period, const std::string &filename, const std::vector< std::string > &vehicleTypes, const std::vector< std::string > &nextEdges, const std::string &detectPersons, const std::string &name, const SUMOTime timeThreshold, const double speedThreshold, const bool openEntry, const bool expectedArrival, const Parameterised::Map ¶meters)=0
Builds a multi entry exit detector (E3)
virtual void buildJpsObstacle(const CommonXMLStructure::SumoBaseObject *sumoBaseObject, const std::string &id, const PositionVector &shape, bool geo, const std::string &name, const Parameterised::Map ¶meters)=0
Builds a JuPedSim obstacle using the given values.
virtual void buildPOIGeo(const CommonXMLStructure::SumoBaseObject *sumoBaseObject, const std::string &id, const std::string &type, const RGBColor &color, const double lon, const double lat, const std::string &icon, const double layer, const double angle, const std::string &imgFile, bool relativePath, const double width, const double height, const std::string &name, const Parameterised::Map ¶meters)=0
Builds a POI in GEO coordinaten using the given values.
virtual void buildDetectorE1Instant(const CommonXMLStructure::SumoBaseObject *sumoBaseObject, const std::string &id, const std::string &laneID, const double pos, const std::string &filename, const std::vector< std::string > &vehicleTypes, const std::vector< std::string > &nextEdges, const std::string &detectPersons, const std::string &name, const bool friendlyPos, const Parameterised::Map ¶meters)=0
Builds a Instant Induction Loop Detector (E1Instant)
virtual void buildJpsWalkableArea(const CommonXMLStructure::SumoBaseObject *sumoBaseObject, const std::string &id, const PositionVector &shape, bool geo, const std::string &name, const Parameterised::Map ¶meters)=0
Builds a JuPedSim walkable area using the given values.
void parseJpsObstacleAttributes(const SUMOSAXAttributes &attrs)
parse juPedSim obstacle attributes
virtual void buildChargingStation(const CommonXMLStructure::SumoBaseObject *sumoBaseObject, const std::string &id, const std::string &laneID, const double startPos, const double endPos, const std::string &name, const double chargingPower, const double efficiency, const bool chargeInTransit, const SUMOTime chargeDelay, const std::string &chargeType, const SUMOTime waitingTime, const bool friendlyPosition, const std::string &parkingAreaID, const Parameterised::Map ¶meters)=0
Builds a charging Station.
void parseVariableSpeedSignAttributes(const SUMOSAXAttributes &attrs)
parse variable speed sign attributes
virtual ~AdditionalHandler()
Destructor.
virtual void buildParkingArea(const CommonXMLStructure::SumoBaseObject *sumoBaseObject, const std::string &id, const std::string &laneID, const double startPos, const double endPos, const std::string &departPos, const std::string &name, const std::vector< std::string > &lines, const bool friendlyPosition, const int roadSideCapacity, const bool onRoad, const double width, const double length, const double angle, const bool lefthand, const Parameterised::Map ¶meters)=0
Builds a Parking Area.
virtual void buildTAZ(const CommonXMLStructure::SumoBaseObject *sumoBaseObject, const std::string &id, const PositionVector &shape, const Position ¢er, const bool fill, const RGBColor &color, const std::vector< std::string > &edgeIDs, const std::string &name, const Parameterised::Map ¶meters)=0
Builds a TAZ (Traffic Assignment Zone)
virtual void buildPOI(const CommonXMLStructure::SumoBaseObject *sumoBaseObject, const std::string &id, const std::string &type, const RGBColor &color, const double x, const double y, const std::string &icon, const double layer, const double angle, const std::string &imgFile, bool relativePath, const double width, const double height, const std::string &name, const Parameterised::Map ¶meters)=0
Builds a POI using the given values.
void parseDestProbRerouteAttributes(const SUMOSAXAttributes &attrs)
parse dest prob reroute attributes
virtual void buildCalibratorFlow(const CommonXMLStructure::SumoBaseObject *sumoBaseObject, const SUMOVehicleParameter &vehicleParameter)=0
builds a calibrator flow
void parseE1Attributes(const SUMOSAXAttributes &attrs)
parse E1 attributes
virtual void buildOverheadWire(const CommonXMLStructure::SumoBaseObject *sumoBaseObject, const std::string &id, const std::string &substationId, const std::vector< std::string > &laneIDs, const double startPos, const double endPos, const bool friendlyPos, const std::vector< std::string > &forbiddenInnerLanes, const Parameterised::Map ¶meters)=0
build overhead wire
void parseVariableSpeedSignStepAttributes(const SUMOSAXAttributes &attrs)
parse variable speed sign step attributes
void parseParameters(const SUMOSAXAttributes &attrs)
parse generic parameters
void parseParkingSpaceAttributes(const SUMOSAXAttributes &attrs)
parse parking space attributes
void parseExitAttributes(const SUMOSAXAttributes &attrs)
parse exist attributes
virtual void buildClosingLaneReroute(const CommonXMLStructure::SumoBaseObject *sumoBaseObject, const std::string &closedLane, SVCPermissions permissions)=0
builds a closing lane reroute
virtual void buildTAZSink(const CommonXMLStructure::SumoBaseObject *sumoBaseObject, const std::string &edgeID, const double arrivalWeight)=0
Builds a TAZSink (Traffic Assignment Zone)
void parseRerouterAttributes(const SUMOSAXAttributes &attrs)
parse rerouter attributes
void parseBusStopAttributes(const SUMOSAXAttributes &attrs)
virtual void buildClosingReroute(const CommonXMLStructure::SumoBaseObject *sumoBaseObject, const std::string &closedEdgeID, SVCPermissions permissions)=0
builds a closing edge reroute
void parseContainerStopAttributes(const SUMOSAXAttributes &attrs)
parse containerStop attributes
virtual void buildMultiLaneDetectorE2(const CommonXMLStructure::SumoBaseObject *sumoBaseObject, const std::string &id, const std::vector< std::string > &laneIDs, const double pos, const double endPos, const SUMOTime period, const std::string &trafficLight, const std::string &filename, const std::vector< std::string > &vehicleTypes, const std::vector< std::string > &nextEdges, const std::string &detectPersons, const std::string &name, const SUMOTime timeThreshold, const double speedThreshold, const double jamThreshold, const bool friendlyPos, const bool show, const Parameterised::Map ¶meters)=0
Builds a multi-lane Area Detector (E2)
void parseParkingAreaAttributes(const SUMOSAXAttributes &attrs)
parse parking area attributes
virtual void buildVaporizer(const CommonXMLStructure::SumoBaseObject *sumoBaseObject, const std::string &edgeID, const SUMOTime from, const SUMOTime endTime, const std::string &name, const Parameterised::Map ¶meters)=0
Builds a vaporizer (lane speed additional)
virtual void buildDetectorExit(const CommonXMLStructure::SumoBaseObject *sumoBaseObject, const std::string &laneID, const double pos, const bool friendlyPos, const Parameterised::Map ¶meters)=0
Builds a exit detector (E3)
virtual void buildContainerStop(const CommonXMLStructure::SumoBaseObject *sumoBaseObject, const std::string &id, const std::string &laneID, const double startPos, const double endPos, const std::string &name, const std::vector< std::string > &lines, const int containerCapacity, const double parkingLength, const RGBColor &color, const bool friendlyPosition, const Parameterised::Map ¶meters)=0
Builds a container stop.
virtual void buildTractionSubstation(const CommonXMLStructure::SumoBaseObject *sumoBaseObject, const std::string &id, const Position &pos, const double voltage, const double currentLimit, const Parameterised::Map ¶meters)=0
build traction substation
virtual void buildBusStop(const CommonXMLStructure::SumoBaseObject *sumoBaseObject, const std::string &id, const std::string &laneID, const double startPos, const double endPos, const std::string &name, const std::vector< std::string > &lines, const int personCapacity, const double parkingLength, const RGBColor &color, const bool friendlyPosition, const Parameterised::Map ¶meters)=0
Builds a bus stop.
virtual void buildAccess(const CommonXMLStructure::SumoBaseObject *sumoBaseObject, const std::string &laneID, const std::string &pos, const double length, const bool friendlyPos, const Parameterised::Map ¶meters)=0
Builds an Access.
void parseRouteProbeAttributes(const SUMOSAXAttributes &attrs)
parse route probe attributes
void parseAccessAttributes(const SUMOSAXAttributes &attrs)
parse access attributes
void parseTAZSourceAttributes(const SUMOSAXAttributes &attrs)
parse TAZ source attributes
void parseVaporizerAttributes(const SUMOSAXAttributes &attrs)
parse vaporizer attributes
virtual void buildParkingAreaReroute(const CommonXMLStructure::SumoBaseObject *sumoBaseObject, const std::string &newParkignAreaID, const double probability, const bool visible)=0
builds a parking area reroute
void parseClosingLaneRerouteAttributes(const SUMOSAXAttributes &attrs)
parse closing lane reroute attributes
void parseRerouterIntervalAttributes(const SUMOSAXAttributes &attrs)
parse rerouter interval attributes
bool isErrorCreatingElement() const
get flag for check if a element wasn't created
void parseEntryAttributes(const SUMOSAXAttributes &attrs)
parse entry attributes
virtual void buildTAZSource(const CommonXMLStructure::SumoBaseObject *sumoBaseObject, const std::string &edgeID, const double departWeight)=0
Builds a TAZSource (Traffic Assignment Zone)
void parsePolyAttributes(const SUMOSAXAttributes &attrs)
void parseClosingRerouteAttributes(const SUMOSAXAttributes &attrs)
parse closing reroute attributes
virtual void buildRouteProbe(const CommonXMLStructure::SumoBaseObject *sumoBaseObject, const std::string &id, const std::string &edgeID, const SUMOTime period, const std::string &name, const std::string &file, const SUMOTime begin, const std::vector< std::string > &vTypes, const Parameterised::Map ¶meters)=0
builds a Route probe
virtual void buildPolygon(const CommonXMLStructure::SumoBaseObject *sumoBaseObject, const std::string &id, const std::string &type, const RGBColor &color, const double layer, const double angle, const std::string &imgFile, const bool relativePath, const PositionVector &shape, const bool geo, const bool fill, const double lineWidth, const std::string &name, const Parameterised::Map ¶meters)=0
Builds a polygon using the given values.
void addIntAttribute(const SumoXMLAttr attr, const int value)
add int attribute into current SumoBaseObject node
const RGBColor & getColorAttribute(const SumoXMLAttr attr) const
get color attribute
SUMOTime getTimeAttribute(const SumoXMLAttr attr) const
get time attribute
const PositionVector & getPositionVectorAttribute(const SumoXMLAttr attr) const
get PositionVector attribute
bool hasStringAttribute(const SumoXMLAttr attr) const
has function
void setTag(const SumoXMLTag tag)
set SumoBaseObject tag
SumoBaseObject * getParentSumoBaseObject() const
get pointer to mySumoBaseObjectParent SumoBaseObject (if is null, then is the root)
const Position & getPositionAttribute(const SumoXMLAttr attr) const
get Position attribute
void addPositionVectorAttribute(const SumoXMLAttr attr, const PositionVector &value)
add PositionVector attribute into current SumoBaseObject node
const std::map< std::string, std::string > & getParameters() const
get parameters
void addBoolAttribute(const SumoXMLAttr attr, const bool value)
add bool attribute into current SumoBaseObject node
SumoXMLTag getTag() const
get XML myTag
void addTimeAttribute(const SumoXMLAttr attr, const SUMOTime value)
add time attribute into current SumoBaseObject node
void addStringListAttribute(const SumoXMLAttr attr, const std::vector< std::string > &value)
add string list attribute into current SumoBaseObject node
int getIntAttribute(const SumoXMLAttr attr) const
get int attribute
void addDoubleAttribute(const SumoXMLAttr attr, const double value)
add double attribute into current SumoBaseObject node
bool hasDoubleAttribute(const SumoXMLAttr attr) const
check if current SumoBaseObject has the given double attribute
void addPositionAttribute(const SumoXMLAttr attr, const Position &value)
add Position attribute into current SumoBaseObject node
bool getBoolAttribute(const SumoXMLAttr attr) const
get bool attribute
SUMOTime getPeriodAttribute() const
get 'period' attribute
void setVehicleParameter(const SUMOVehicleParameter *vehicleParameter)
set vehicle parameters
void addStringAttribute(const SumoXMLAttr attr, const std::string &value)
add string attribute into current SumoBaseObject node
double getDoubleAttribute(const SumoXMLAttr attr) const
get double attribute
const SUMOVehicleParameter & getVehicleParameter() const
get vehicle parameters
const std::vector< std::string > & getStringListAttribute(const SumoXMLAttr attr) const
get string list attribute
void addColorAttribute(const SumoXMLAttr attr, const RGBColor &value)
add color attribute into current SumoBaseObject node
const std::string & getStringAttribute(const SumoXMLAttr attr) const
get string attribute
const std::vector< SumoBaseObject * > & getSumoBaseObjectChildren() const
get SumoBaseObject children
void abortSUMOBaseOBject()
abort SUMOBaseOBject
CommonXMLStructure::SumoBaseObject * getCurrentSumoBaseObject() const
get current editedSumoBaseObject
void openSUMOBaseOBject()
open SUMOBaseOBject
void closeSUMOBaseOBject()
close SUMOBaseOBject
A point in 2D or 3D with translation and scaling methods.
static const Position INVALID
used to indicate that a position is valid
static const RGBColor INVISIBLE
static const RGBColor RED
named colors
Encapsulated SAX-Attributes.
virtual std::string getString(int id, bool *isPresent=nullptr) const =0
Returns the string-value of the named (by its enum-value) attribute.
SUMOTime getOptPeriod(const char *objectid, bool &ok, SUMOTime defaultValue, bool report=true) const
Tries to read the SUMOTime 'period' attribute.
T getOpt(int attr, const char *objectid, bool &ok, T defaultValue=T(), bool report=true) const
Tries to read given attribute assuming it is an int.
SUMOTime getOptSUMOTimeReporting(int attr, const char *objectid, bool &ok, SUMOTime defaultValue, bool report=true) const
Tries to read given attribute assuming it is a SUMOTime.
T get(int attr, const char *objectid, bool &ok, bool report=true) const
Tries to read given attribute assuming it is an int.
virtual bool hasAttribute(int id) const =0
Returns the information whether the named (by its enum-value) attribute is within the current list.
SUMOTime getSUMOTimeReporting(int attr, const char *objectid, bool &ok, bool report=true) const
Tries to read given attribute assuming it is a SUMOTime.
Structure representing possible vehicle parameter.
SUMOTime repetitionOffset
The time offset between vehicle reinsertions.
long long int parametersSet
Information for the router which parameter were set, TraCI may modify this (when changing color)
SUMOTime repetitionEnd
The time at which the flow ends (only needed when using repetitionProbability)
double calibratorSpeed
speed (used by calibrator flows
static SUMOVehicleParameter * parseVehicleAttributes(int element, const SUMOSAXAttributes &attrs, const bool hardFail, const bool optionalID=false, const bool skipDepart=false, const bool allowInternalRoutes=false)
Parses a vehicle's attributes.
static StringBijection< PersonMode > PersonModeValues
person modes
static StringBijection< POIIcon > POIIcons
POI icon values.
static bool isValidParameterKey(const std::string &value)
whether the given string is a valid key for a parameter
static const bool DEFAULT_RELATIVEPATH
static const double DEFAULT_LAYER
static const double DEFAULT_LAYER_POI
static const double DEFAULT_IMG_WIDTH
static const std::string DEFAULT_IMG_FILE
static const double DEFAULT_LINEWIDTH
static const double DEFAULT_ANGLE
static const double DEFAULT_IMG_HEIGHT
static const std::string DEFAULT_TYPE
const std::string & getString(const T key) const
bool hasString(const std::string &str) const