20 #ifndef GNEAdditionalHandler_h 21 #define GNEAdditionalHandler_h 339 static bool buildVariableSpeedSign(
GNEViewNet* viewNet,
const std::string&
id,
Position pos,
const std::vector<GNELane*>& destLanes,
const std::string& file,
const std::map<SUMOReal, SUMOReal>& VSSValues);
void parseVariableSpeedSignStep(const SUMOSAXAttributes &attrs, const SumoXMLTag &tag)
Parses step values of VariableSpeedSigns.
SumoXMLTag
Numbers representing SUMO-XML - element names.
void parseCalibratorFlow(const SUMOSAXAttributes &attrs, const SumoXMLTag &tag)
Parses flow values of Calibrators.
void parseAndBuildDetectorE1(const SUMOSAXAttributes &attrs, const SumoXMLTag &tag)
Parses his values and builds a induction loop detector (E1)
void myStartElement(int element, const SUMOSAXAttributes &attrs)
Called on the opening of a tag;.
static bool buildDetectorEntry(GNEViewNet *viewNet, GNEDetectorE3 *E3Parent, GNELane *lane, SUMOReal pos)
Builds a entry detector (E3)
void parseAndBuildChargingStation(const SUMOSAXAttributes &attrs, const SumoXMLTag &tag)
Parses his values and builds a charging station.
static bool buildVaporizer(GNEViewNet *viewNet, const std::string &id, GNEEdge *edge, SUMOReal startTime, SUMOReal end)
Builds a vaporizer (lane speed trigger)
GNEAdditionalHandler(const std::string &file, GNEViewNet *viewNet)
Constructor.
static bool buildAdditional(GNEViewNet *viewNet, SumoXMLTag tag, std::map< SumoXMLAttr, std::string > values)
Build additionals.
void parseAndBuildDetectorExit(const SUMOSAXAttributes &attrs, const SumoXMLTag &tag)
Parses his values and builds a Exit detector.
A NBNetBuilder extended by visualisation and editing capabilities.
This lane is powered by an underlying GNEEdge and basically knows how to draw itself.
static bool buildRouteProbe(GNEViewNet *viewNet, const std::string &id, GNEEdge *edge, SUMOReal freq, const std::string &file, SUMOReal begin)
builds a Route probe
SumoXMLAttr
Numbers representing SUMO-XML - attributes.
static bool buildChargingStation(GNEViewNet *viewNet, const std::string &id, GNELane *lane, SUMOReal startPos, SUMOReal endPos, SUMOReal chargingPower, SUMOReal efficiency, bool chargeInTransit, SUMOReal chargeDelay)
Builds a charging Station.
SAX-handler base for SUMO-files.
static bool buildDetectorE3(GNEViewNet *viewNet, const std::string &id, Position pos, SUMOReal freq, const std::string &filename, const SUMOReal timeThreshold, SUMOReal speedThreshold)
Builds a multi entry exit detector (E3)
Builds trigger objects for GNENet (busStops, chargingStations, detectors, etc..)
void parseAndBuildVariableSpeedSign(const SUMOSAXAttributes &attrs, const SumoXMLTag &tag)
Parses his values and builds a Variable Speed Signal (lane speed trigger)
void parseAndBuildDetectorE2(const SUMOSAXAttributes &attrs, const SumoXMLTag &tag)
Parses his values and builds a lane area detector (E2)
bool checkStopPos(SUMOReal &startPos, SUMOReal &endPos, const SUMOReal laneLength, const SUMOReal minLength, const bool friendlyPos)
check if the position of an stoppingPlace over a lane is valid
static bool buildContainerStop(GNEViewNet *viewNet, const std::string &id, GNELane *lane, SUMOReal startPos, SUMOReal endPos, const std::vector< std::string > &lines)
Builds a container stop.
static bool buildVariableSpeedSign(GNEViewNet *viewNet, const std::string &id, Position pos, const std::vector< GNELane * > &destLanes, const std::string &file, const std::map< SUMOReal, SUMOReal > &VSSValues)
Builds a VariableSpeedSign (lane speed trigger)
static bool buildDetectorE1(GNEViewNet *viewNet, const std::string &id, GNELane *lane, SUMOReal pos, SUMOReal freq, const std::string &filename, bool splitByType)
Builds a induction loop detector (E1)
bool getFriendlyPosition(const SUMOSAXAttributes &attrs, const char *objectid)
get special attribute friendly position, used in stopping places
static bool buildDetectorExit(GNEViewNet *viewNet, GNEDetectorE3 *E3Parent, GNELane *lane, SUMOReal pos)
Builds a exit detector (E3)
~GNEAdditionalHandler()
Destructor.
const std::string & getFileName() const
returns the current file name
static bool buildBusStop(GNEViewNet *viewNet, const std::string &id, GNELane *lane, SUMOReal startPos, SUMOReal endPos, const std::vector< std::string > &lines)
Builds a bus stop.
Encapsulated SAX-Attributes.
A point in 2D or 3D with translation and scaling methods.
void parseAndBuildRerouter(const SUMOSAXAttributes &attrs, const SumoXMLTag &tag)
Parses his values and builds a rerouter.
bool checkAdditionalParent(SumoXMLTag currentTag)
used to check hierarchy of aditionals with parents and childs (for example, E3)
GNEViewNet * myViewNet
pointer to View's Net
void parseAndBuildDetectorE3(const SUMOSAXAttributes &attrs, const SumoXMLTag &tag)
Parses his values and builds a multi entry exit detector (E3)
void parseAndBuildRouteProbe(const SUMOSAXAttributes &attrs, const SumoXMLTag &tag)
Parses his values and builds routeProbe.
GNEDetectorE3 * myE3Parent
Pointer to the last inserted E3.
A road/street connecting two junctions (netedit-version)
static bool buildRerouter(GNEViewNet *viewNet, const std::string &id, Position pos, const std::vector< GNEEdge * > &edges, SUMOReal prob, const std::string &file, bool off)
builds a rerouter
void parseAndBuildCalibrator(const SUMOSAXAttributes &attrs, const SumoXMLTag &tag)
Parses his values and builds a mesoscopic or microscopic calibrator.
void parseAndBuildBusStop(const SUMOSAXAttributes &attrs, const SumoXMLTag &tag)
Parses his values and builds a bus stop.
void parseAndBuildContainerStop(const SUMOSAXAttributes &attrs, const SumoXMLTag &tag)
Parses his values and builds a container stop.
static T getParsedAttribute(const SUMOSAXAttributes &attrs, const char *objectid, SumoXMLTag tag, SumoXMLAttr attribute, bool &abort, bool report=true)
get parsed attribute of XML and show warnings if there are problems
void parseAndBuildVaporizer(const SUMOSAXAttributes &attrs, const SumoXMLTag &tag)
Builds a vaporization.
static bool buildCalibrator(GNEViewNet *viewNet, const std::string &id, GNEEdge *edge, SUMOReal pos, const std::string &outfile, SUMOReal freq, const std::vector< GNECalibrator::GNECalibratorFlow * > &flowValues)
builds a microscopic calibrator
SUMOReal getPosition(const SUMOSAXAttributes &attrs, GNELane &lane, const std::string &tt, const std::string &tid)
extracts the position, checks whether it shall be mirrored and checks whether it is within the lane...
void resetLastTag()
reset last Tag and clear non-valid Additionals (For example, created E3 withouts Entry/Exit childs) ...
SumoXMLTag myLastTag
last used Tag
GNERerouterInterval * rerouterIntervalToInsertValues
pointer to rerouterInterval in which insert GNEClosingReroute, GNEDestProbReroute, etc.
void parseAndBuildDetectorEntry(const SUMOSAXAttributes &attrs, const SumoXMLTag &tag)
Parses his values and builds a Entry detector.
static bool buildDetectorE2(GNEViewNet *viewNet, const std::string &id, GNELane *lane, SUMOReal pos, SUMOReal length, SUMOReal freq, const std::string &filename, bool cont, const SUMOReal timeThreshold, SUMOReal speedThreshold, SUMOReal jamThreshold)
Builds a lane Area Detector (E2)