38 const std::string& name,
const std::string& filename,
SUMOTime begin) :
40 {}, {edge}, {}, {}, {}, {}, {}, {}),
41 myFrequency(frequency),
45 updateCenteringBoundary(
false);
97 RGBColor routeProbeColor, centralLineColor;
117 glTranslated(0, 0, .1);
131 glRotated(180, 0, 0, 1);
259 return canParse<SUMOTime>(value);
262 return canParse<SUMOTime>(value);
264 return canParse<bool>(value);
292 myBegin = parse<SUMOTime>(value);
295 if (parse<bool>(value)) {
@ GLO_ROUTEPROBE
a RouteProbe
@ GNETEXTURE_ROUTEPROBESELECTED
std::string time2string(SUMOTime t)
convert SUMOTime to string
@ SUMO_TAG_ROUTEPROBE
a routeprobe detector
SumoXMLAttr
Numbers representing SUMO-XML - attributes.
@ GNE_ATTR_SELECTED
element is selected
@ SUMO_ATTR_BEGIN
weights: time range begin
@ GNE_ATTR_PARAMETERS
parameters "key1=value1|key2=value2|...|keyN=valueN"
std::string toString(const T &t, std::streamsize accuracy=gPrecision)
Boundary & grow(double by)
extends the boundary by the given amount
static void setColor(const RGBColor &c)
Sets the gl-color to this value.
static void drawBoxLine(const Position &beg, double rot, double visLength, double width, double offset=0)
Draws a thick line.
An Element which don't belongs to GNENet but has influency in the simulation.
const std::string & getID() const
get ID
GNEGeometry::Geometry myAdditionalGeometry
geometry to be precomputed in updateGeometry(...)
void replaceAdditionalParentEdges(const std::string &value)
replace additional parent edges
void calculatePerpendicularLine(const double endLaneposition)
calculate perpendicular line between lane parents
std::string myAdditionalName
name of additional
void drawAdditionalName(const GUIVisualizationSettings &s) const
draw additional name
Boundary myBoundary
Additional Boundary.
bool isValidAdditionalID(const std::string &newID) const
check if a new additional ID is valid
bool isAttributeCarrierSelected() const
check if attribute carrier is selected
friend class GNEChange_Attribute
declare friend class
const std::string & getTagStr() const
get tag assigned to this object in string format
void unselectAttributeCarrier(const bool changeFlag=true)
unselect attribute carrier using GUIGlobalSelection
bool drawUsingSelectColor() const
check if attribute carrier must be drawn using selecting color.
GNENet * myNet
pointer to net
void selectAttributeCarrier(const bool changeFlag=true)
select attribute carrier using GUIGlobalSelection
A road/street connecting two junctions (netedit-version)
const std::vector< double > & getShapeRotations() const
The rotations of the single shape parts.
const PositionVector & getShape() const
The shape of the additional element.
const std::vector< GNEEdge * > & getParentEdges() const
get parent edges
void updateID(GNEAttributeCarrier *AC, const std::string newID)
update ID
A NBNetBuilder extended by visualisation and editing capabilities.
GNEEdge * retrieveEdge(const std::string &id, bool failHard=true) const
get edge by id
GNENetHelper::AttributeCarriers * getAttributeCarriers() const
retrieve all attribute carriers of Net
GNEViewNet * getViewNet() const
get view net
std::string getHierarchyName() const
get Hierarchy Name (Used in AC Hierarchy)
SUMOTime myBegin
begin of rerouter
GNERouteProbe(const std::string &id, GNENet *net, GNEEdge *edge, const std::string &frequency, const std::string &name, const std::string &filename, SUMOTime begin)
Constructor.
void updateCenteringBoundary(const bool updateGrid)
update centering boundary (implies change in RTREE)
void setMoveShape(const GNEMoveResult &moveResult)
set move shape
std::string getParentName() const
Returns the name of the parent object (if any)
std::string myFilename
filename of RouteProbe
bool isAttributeEnabled(SumoXMLAttr key) const
void setAttribute(SumoXMLAttr key, const std::string &value, GNEUndoList *undoList)
method for setting the attribute and letting the object perform additional changes
void updateGeometry()
update pre-computed geometry information
void commitMoveShape(const GNEMoveResult &moveResult, GNEUndoList *undoList)
commit move shape
~GNERouteProbe()
Destructor.
bool isValid(SumoXMLAttr key, const std::string &value)
method for checking if the key and their conrrespond attribute are valids
GNEMoveOperation * getMoveOperation(const double shapeOffset)
get move operation for the given shapeOffset
std::string getPopUpID() const
get PopPup ID (Used in AC Hierarchy)
std::string getAttribute(SumoXMLAttr key) const
double getAttributeDouble(SumoXMLAttr key) const
std::string myFrequency
Frequency of RouteProbe.
void drawGL(const GUIVisualizationSettings &s) const
Draws the object.
void splitEdgeGeometry(const double splitPosition, const GNENetworkElement *originalElement, const GNENetworkElement *newElement, GNEUndoList *undoList)
split geometry
void p_add(GNEChange_Attribute *cmd)
special method, avoid empty changes, always execute
const GNEViewNetHelper::DataViewOptions & getDataViewOptions() const
get data view options
const GNEAttributeCarrier * getFrontAttributeCarrier() const
get front attributeCarrier
bool isAttributeCarrierInspected(const GNEAttributeCarrier *AC) const
check if attribute carrier is being inspected
void drawTranslateFrontAttributeCarrier(const GNEAttributeCarrier *AC, GUIGlObjectType objectType, const double extraOffset=0)
draw front attributeCarrier
GUIGlID getGlID() const
Returns the numerical id of the object.
static GUIGlID getTexture(GUITexture which)
returns a texture previously defined in the enum GUITexture
static void drawTexturedBox(int which, double size)
Draws a named texture as a box with the given size.
Stores the information about how to visualize structures.
bool drawForRectangleSelection
whether drawing is performed for the purpose of selecting objects using a rectangle
GUIVisualizationDetailSettings detailSettings
detail settings
GUIVisualizationSizeSettings addSize
bool drawDottedContour() const
check if dotted contour can be drawn
bool drawAdditionals(const double exaggeration) const
check if additionals must be drawn
GUIVisualizationColorSettings colorSettings
color settings
bool drawDetail(const double detail, const double exaggeration) const
check if details can be drawn for the given GUIVisualizationDetailSettings and current scale and exxa...
GUIVisualizationAdditionalSettings additionalSettings
Additional settings.
static bool areParametersValid(const std::string &value, bool report=false, ParameterisedAttrType attrType=ParameterisedAttrType::STRING, const std::string kvsep="=", const std::string sep="|")
check if given string can be parsed to a parameters map "key1=value1|key2=value2|....
void setParametersStr(const std::string ¶msString, const std::string kvsep="=", const std::string sep="|")
set the inner key/value map in string format "key1=value1|key2=value2|...|keyN=valueN"
std::string getParametersStr(const std::string kvsep="=", const std::string sep="|") const
Returns the inner key/value map in string format "key1=value1|key2=value2|...|keyN=valueN".
A point in 2D or 3D with translation and scaling methods.
Boundary getBoxBoundary() const
Returns a boundary enclosing this list of lines.
static const RGBColor WHITE
RGBColor changedBrightness(int change, int toChange=3) const
Returns a new color with altered brightness.
static bool isValidFilename(const std::string &value)
whether the given string is a valid attribute for a filename (for example, a name)
static bool isValidAttribute(const std::string &value)
whether the given string is a valid attribute for a certain key (for example, a name)
static void drawDottedContourShape(const DottedContourType type, const GUIVisualizationSettings &s, const PositionVector &shape, const double width, const double exaggeration)
draw dotted contour for the given shape (used by additionals)
static void rotateOverLane(const double rot)
rotate over lane (used by Lock icons, detector logos, etc.)
static void drawGeometry(const GNEViewNet *viewNet, const Geometry &geometry, const double width)
draw geometry
bool showAdditionals() const
check if additionals has to be drawn
static const double routeProbeSize
RouteProbe size.
static const RGBColor routeProbeColor
color for route probes
RGBColor selectedAdditionalColor
additional selection color (busStops, Detectors...)
static const double laneTextures
details for lane textures
double getExaggeration(const GUIVisualizationSettings &s, const GUIGlObject *o, double factor=20) const
return the drawing size including exaggeration and constantSize values