23 #ifndef NLDetectorBuilder_h
24 #define NLDetectorBuilder_h
100 const std::string& device,
bool friendlyPos,
101 const std::string& vTypes);
120 const std::string& lane,
SUMOReal pos,
121 const std::string& device,
bool friendlyPos,
122 const std::string& vTypes);
150 bool cont,
SUMOTime splInterval,
const std::string& device,
SUMOTime haltingTimeThreshold,
153 const std::string& vTypes);
182 const std::string& device,
SUMOTime haltingTimeThreshold,
185 const std::string& vTypes);
215 const std::string& device,
SUMOTime haltingTimeThreshold,
218 const std::string& vTypes);
236 const std::string& vTypes);
305 const std::string& vtype,
SUMOTime frequency,
306 const std::string& device);
325 const std::string& device,
326 const std::string& vTypes);
348 const std::string& vTypes,
bool show =
true);
362 const std::string& vTypes);
381 const std::string& vTypes);
401 const std::string& vTypes);
417 const std::string& vTypes);
439 const bool useLanes,
const bool withEmpty,
const bool printDefaults,
440 const bool withInternal,
const bool trackVehicles,
442 const SUMOReal haltSpeed,
const std::string& vTypes,
443 const std::string& device);
464 const std::string& vTypes);
482 const std::string& vTypes);
502 const std::string& device,
SUMOReal haltingSpeedThreshold,
504 const std::string& vTypes);
555 const std::string& detid);
593 const std::string& detid);
603 const std::string& detid);
SumoXMLTag
Numbers representing SUMO-XML - element names.
Builds detectors for microsim.
virtual MSDetectorFileOutput * createInstantInductLoop(const std::string &id, MSLane *lane, SUMOReal pos, const std::string &od, const std::string &vTypes)
Creates an instance of an e1 detector using the given values.
Storage for all programs of a single tls.
MSLane * getLaneChecking(const std::string &laneID, SumoXMLTag type, const std::string &detid)
Returns the named lane.
NLDetectorBuilder & operator=(const NLDetectorBuilder &)
Invalidated assignment operator.
An areal (along a single lane) detector.
void addE3Entry(const std::string &lane, SUMOReal pos, bool friendlyPos)
Builds an entry point of an e3 detector.
const std::string myID
The id of the detector.
MSDetectorFileOutput * buildMultiLaneE2Det(const std::string &id, DetectorUsage usage, MSLane *lane, SUMOReal pos, SUMOReal length, SUMOTime haltingTimeThreshold, SUMOReal haltingSpeedThreshold, SUMOReal jamDistThreshold, const std::string &vTypes)
Builds an e2 detector that continues on preceeding lanes.
void addE3Exit(const std::string &lane, SUMOReal pos, bool friendlyPos)
Builds an exit point of an e3 detector.
std::vector< MSCrossSection > CrossSectionVector
void buildRouteProbe(const std::string &id, const std::string &edge, SUMOTime frequency, SUMOTime begin, const std::string &device, const std::string &vTypes)
Builds a routeProbe and adds it to the net.
void buildInstantInductLoop(const std::string &id, const std::string &lane, SUMOReal pos, const std::string &device, bool friendlyPos, const std::string &vTypes)
Builds an instantenous induction and adds it to the net.
~E3DetectorDefinition()
Destructor.
void createEdgeLaneMeanData(const std::string &id, SUMOTime frequency, SUMOTime begin, SUMOTime end, const std::string &type, const bool useLanes, const bool withEmpty, const bool printDefaults, const bool withInternal, const bool trackVehicles, const SUMOReal maxTravelTime, const SUMOReal minSamples, const SUMOReal haltSpeed, const std::string &vTypes, const std::string &device)
Creates edge based mean data collector using the given specification.
void buildInductLoop(const std::string &id, const std::string &lane, SUMOReal pos, SUMOTime splInterval, const std::string &device, bool friendlyPos, const std::string &vTypes)
Builds an e1 detector and adds it to the net.
void buildVTypeProbe(const std::string &id, const std::string &vtype, SUMOTime frequency, const std::string &device)
Builds a vTypeProbe and adds it to the net.
void endE3Detector()
Builds of an e3 detector using collected values.
void convUncontE2PosLength(const std::string &id, MSLane *clane, SUMOReal &pos, SUMOReal &length, bool frinedly_pos)
Converts the length and the position information for an e2 detector.
The simulated network and simulation perfomer.
E3DetectorDefinition & operator=(const E3DetectorDefinition &)
Invalidated assignment operator.
virtual MSDetectorFileOutput * createE3Detector(const std::string &id, const CrossSectionVector &entries, const CrossSectionVector &exits, SUMOReal haltingSpeedThreshold, SUMOTime haltingTimeThreshold, const std::string &vTypes)
Creates an instance of an e3 detector using the given values.
const std::string myVehicleTypes
The device the detector shall use.
A road/street connecting two junctions.
Holds the incoming definitions of an e3 detector unless the detector is build.
MSE2Collector * buildSingleLaneE2Det(const std::string &id, DetectorUsage usage, MSLane *lane, SUMOReal pos, SUMOReal length, SUMOTime haltingTimeThreshold, SUMOReal haltingSpeedThreshold, SUMOReal jamDistThreshold, const std::string &vTypes)
Builds an e2 detector that lies on only one lane.
std::string getCurrentE3ID() const
Returns the id of the currently built e3 detector.
void buildE2Detector(const std::string &id, const std::string &lane, SUMOReal pos, SUMOReal length, bool cont, SUMOTime splInterval, const std::string &device, SUMOTime haltingTimeThreshold, SUMOReal haltingSpeedThreshold, SUMOReal jamDistThreshold, bool friendlyPos, const std::string &vTypes)
Builds an e2 detector with a fixed interval and adds it to the net.
virtual MSDetectorFileOutput * createInductLoop(const std::string &id, MSLane *lane, SUMOReal pos, const std::string &vTypes, bool show=true)
Creates an instance of an e1 detector using the given values.
SUMOReal myHaltingSpeedThreshold
The speed a vehicle's speed must be below to be assigned as jammed.
CrossSectionVector myExits
List of detector's exits.
MSEdge * getEdgeChecking(const std::string &edgeID, SumoXMLTag type, const std::string &detid)
Returns the named edge.
SUMOTime mySampleInterval
The aggregation interval.
virtual MSDetectorFileOutput * createMultiLaneE2Detector(const std::string &id, DetectorUsage usage, MSLane *lane, SUMOReal pos, SUMOTime haltingTimeThreshold, SUMOReal haltingSpeedThreshold, SUMOReal jamDistThreshold, const std::string &vTypes)
Creates an instance of an e2ol-detector using the given values.
void convContE2PosLength(const std::string &id, MSLane *clane, SUMOReal &pos, SUMOReal &length, bool frinedly_pos)
Converts the length and the position information for an e2ol-detector.
NLDetectorBuilder(MSNet &net)
Constructor.
A single mesoscopic segment (cell)
void checkSampleInterval(SUMOTime splInterval, SumoXMLTag type, const std::string &id)
Checks whether the given frequency (sample interval) is valid.
virtual MSE2Collector * createSingleLaneE2Detector(const std::string &id, DetectorUsage usage, MSLane *lane, SUMOReal pos, SUMOReal length, SUMOTime haltingTimeThreshold, SUMOReal haltingSpeedThreshold, SUMOReal jamDistThreshold, const std::string &vTypes)
Creates an instance of an e2 detector using the given values.
virtual ~NLDetectorBuilder()
Destructor.
E3DetectorDefinition * myE3Definition
definition of the currently parsed e3 detector
void beginE3Detector(const std::string &id, const std::string &device, SUMOTime splInterval, SUMOReal haltingSpeedThreshold, SUMOTime haltingTimeThreshold, const std::string &vTypes)
Stores temporary the initial information about an e3 detector to build.
MSNet & myNet
The net to fill.
CrossSectionVector myEntries
List of detector's entries.
Representation of a lane in the micro simulation.
SUMOReal getPositionChecking(SUMOReal pos, MSLane *lane, bool friendlyPos, const std::string &detid)
Computes the position to use.
const std::string myDevice
The device the detector shall use.
An induction loop for mesoscopic simulation.
Base of value-generating classes (detectors)
SUMOTime myHaltingTimeThreshold
The time a vehicle's speed must be below haltingSpeedThreshold to be assigned as jammed.
E3DetectorDefinition(const std::string &id, const std::string &device, SUMOReal haltingSpeedThreshold, SUMOTime haltingTimeThreshold, SUMOTime splInterval, const std::string &vTypes)
Constructor.