 |
Eclipse SUMO - Simulation of Urban MObility
|
Go to the documentation of this file.
20 #ifndef MSDetectorFileOutput_h
21 #define MSDetectorFileOutput_h
149 for (
auto vTypeDist : vTypeDists) {
virtual void writeXMLDetectorProlog(OutputDevice &dev) const =0
Open the XML-output.
#define UNUSED_PARAMETER(x)
Representation of a vehicle or person.
virtual GUIDetectorWrapper * buildDetectorGUIRepresentation()
Builds the graphical representation.
Base of value-generating classes (detectors)
Base class for objects which have an id.
MSDetectorFileOutput(const std::string &id, const std::string &vTypes, const int detectPersons=false)
Constructor.
std::set< std::string > myVehicleTypes
The vehicle types to look for (empty means all)
Static storage of an output device and its base (abstract) implementation.
virtual const MSVehicleType & getVehicleType() const =0
Returns the vehicle's type.
virtual bool isVehicle() const =0
Get the vehicle's ID.
MSDetectorFileOutput(const std::string &id, const std::set< std::string > &vTypes, const int detectPersons=false)
Constructor.
const int myDetectPersons
Whether pedestrians shall be detected instead of vehicles.
bool isTyped() const
Checks whether the detector is type specific.
MSDetectorFileOutput & operator=(const MSDetectorFileOutput &)
Invalidated assignment operator.
const std::string & getOriginalID() const
Returns the id of the original vehicle type if this is a vehicle specific type, the id otherwise.
const std::set< std::string > getVTypeDistributionMembership(const std::string &id) const
Return the distribution IDs the vehicle type is a member of.
virtual void writeXMLOutput(OutputDevice &dev, SUMOTime startTime, SUMOTime stopTime)=0
Write the generated output to the given device.
virtual void reset()
Resets collected values.
virtual void detectorUpdate(const SUMOTime step)
Updates the detector (computes values)
bool detectPersons() const
static MSNet * getInstance()
Returns the pointer to the unique instance of MSNet (singleton).
bool vehicleApplies(const SUMOTrafficObject &veh) const
Checks whether the detector measures vehicles of the given type.
std::vector< std::string > getVector()
return vector of strings
MSVehicleControl & getVehicleControl()
Returns the vehicle control.
virtual ~MSDetectorFileOutput()
(virtual) destructor