44 std::vector<std::string>
46 std::vector<std::string> ids;
54 std::vector<std::string> ids;
83 std::vector<std::string>
107 std::vector<libsumo::TraCIVehicleData>
110 std::vector<libsumo::TraCIVehicleData> tvd;
111 for (std::vector<MSInductLoop::VehicleData>::const_iterator vdi = vd.begin(); vdi != vd.end(); ++vdi) {
113 tvd.back().id = vdi->idM;
114 tvd.back().length = vdi->lengthM;
115 tvd.back().entryTime = vdi->entryTimeM;
116 tvd.back().leaveTime = vdi->leaveTimeM;
117 tvd.back().typeID = vdi->typeIDM;
139 const float cmin[2] = {(float) p.
x(), (float) p.
y()};
140 const float cmax[2] = {(float) p.
x(), (float) p.
y()};
141 t->
Insert(cmin, cmax, il);
void Insert(const float a_min[2], const float a_max[2], Named *const &a_data)
Insert entry.
const MSLane * getLane() const
Returns the lane the reminder works on.
alternative tag for e1 detector
mirrors MSInductLoop::VehicleData
static std::string getLaneID(const std::string &detID)
int size() const
Returns the number of stored items within the container.
double y() const
Returns the y-position.
std::vector< std::string > getCurrentVehicleIDs() const
Returns the ids of vehicles that have passed the detector.
T get(const std::string &id) const
Retrieves an item.
A RT-tree for efficient storing of SUMO's Named objects.
double x() const
Returns the x-position.
static MSNet * getInstance()
Returns the pointer to the unique instance of MSNet (singleton).
double getCurrentLength() const
Returns the length of the vehicle on the detector.
const PositionVector & getShape() const
Returns this lane's shape.
const std::string & getID() const
Returns the id.
void insertIDs(std::vector< std::string > &into) const
static std::vector< std::string > getIDList()
static double getLastStepOccupancy(const std::string &detID)
A point in 2D or 3D with translation and scaling methods.
double getCurrentSpeed() const
Returns the speed of the vehicle on the detector.
static double getTimeSinceDetection(const std::string &detID)
double getPosition() const
Returns the position of the detector on the lane.
static std::vector< std::string > getLastStepVehicleIDs(const std::string &detID)
static MSInductLoop * getDetector(const std::string &detID)
MSDetectorControl & getDetectorControl()
Returns the detector control.
double getTimeSinceLastDetection() const
Returns the time since the last vehicle left the detector.
int getCurrentPassedNumber() const
Returns the number of vehicles that have passed the detector.
static int getLastStepVehicleNumber(const std::string &detID)
static std::vector< libsumo::TraCIVehicleData > getVehicleData(const std::string &detID)
static double getLastStepMeanSpeed(const std::string &detID)
static NamedRTree * getTree()
Returns a tree filled with inductive loop instances.
virtual std::vector< VehicleData > collectVehiclesOnDet(SUMOTime t, bool leaveTime=false) const
Returns vehicle data for vehicles that have been on the detector starting at the given time...
static double getPosition(const std::string &detID)
const NamedObjectCont< MSDetectorFileOutput * > & getTypedDetectors(SumoXMLTag type) const
Returns the list of detectors of the given type.
double getCurrentOccupancy() const
Returns the current occupancy.
Position positionAtOffset(double pos, double lateralOffset=0) const
Returns the position at the given length.
An unextended detector measuring at a fixed position on a fixed lane.
static double getLastStepMeanLength(const std::string &detID)