47 std::vector<std::string>
49 std::vector<std::string> ids;
123 POI::setParameter(
const std::string& poiID,
const std::string& param,
const std::string& value) {
143 for (
const auto& i : shapeCont.
getPOIs()) {
144 const float cmin[2] = {(float)i.second->x(), (float)i.second->y()};
145 const float cmax[2] = {(float)i.second->x(), (float)i.second->y()};
146 t->
Insert(cmin, cmax, i.second);
void Insert(const float a_min[2], const float a_max[2], Named *const &a_data)
Insert entry.
static const std::string DEFAULT_IMG_FILE
static NamedRTree * getTree()
Returns a tree filled with PoI instances.
double z() const
Returns the z-position.
static bool remove(const std::string &poiID, int layer=0)
static void setColor(const std::string &poiID, const TraCIColor &c)
double y() const
Returns the y-position.
T get(const std::string &id) const
Retrieves an item.
static const double DEFAULT_IMG_HEIGHT
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).
Storage for geometrical objects.
void set(double x, double y)
set positions x and y
void insertIDs(std::vector< std::string > &into) const
static bool add(const std::string &poiID, const TraCIPosition &pos, const TraCIColor &c, const std::string &type, int layer)
static void setPosition(const std::string &poiID, const TraCIPosition &pos)
ShapeContainer & getShapeContainer()
Returns the shapes container.
virtual bool removePOI(const std::string &id)
Removes a PoI from the container.
static TraCIPosition getPosition(const std::string &poiID)
static TraCIColor makeTraCIColor(const RGBColor &color)
void setParameter(const std::string &key, const std::string &value)
Sets a parameter.
static std::string getParameter(const std::string &poiID, const std::string ¶m)
static void setType(const std::string &poiID, const std::string &setType)
static std::vector< std::string > getIDList()
const std::string & getType() const
Returns the (abstract) type of the Shape.
void setType(const std::string &type)
Sets a new type.
const RGBColor & getColor() const
Returns the color of the Shape.
virtual bool addPOI(const std::string &id, const std::string &type, const RGBColor &color, const Position &pos, bool geo, const std::string &lane, double posOverLane, double posLat, double layer, double angle, const std::string &imgFile, double width, double height, bool ignorePruning=false)
Builds a POI using the given values and adds it to the container.
static std::string getType(const std::string &poiID)
const std::string getParameter(const std::string &key, const std::string &defaultValue="") const
Returns the value for a given key.
static Position makePosition(const TraCIPosition &position)
static PointOfInterest * getPoI(const std::string &id)
static const double DEFAULT_IMG_WIDTH
static RGBColor makeRGBColor(const TraCIColor &color)
static void setParameter(const std::string &poiID, const std::string ¶m, const std::string &value)
static TraCIColor getColor(const std::string &poiID)
void setColor(const RGBColor &col)
Sets a new color.
static const double DEFAULT_ANGLE
const POIs & getPOIs() const
Returns all pois.