40 GUIGlObject(net->getTagPropertiesDatabase()->getTagProperty(tag, true)->getGLType(),
"",
41 GUIIconSubSys::getIcon(net->getTagPropertiesDatabase()->getTagProperty(tag, true)->getGUIIcon())),
43 myDataIntervalParent(nullptr) {
48 GNEAttributeCarrier(tag, dataIntervalParent->getNet(), dataIntervalParent->getFilename(), false),
49 GUIGlObject(dataIntervalParent->getNet()->getTagPropertiesDatabase()->getTagProperty(tag, true)->getGLType(), dataIntervalParent->getID(),
50 GUIIconSubSys::getIcon(dataIntervalParent->getNet()->getTagPropertiesDatabase()->getTagProperty(tag, true)->getGUIIcon())),
53 myDataIntervalParent(dataIntervalParent) {
108 if (edgeDataFrame->shown()) {
220 new FXMenuSeparator(ret);
235 if (tagProperty->isUnique()) {
236 ret->
mkItem(tagProperty->getAttrStr().c_str(),
false,
getAttribute(tagProperty->getAttr()));
238 ret->
mkItem(tagProperty->getAttrStr().c_str(),
true,
getAttribute(tagProperty->getAttr()));
357 if (newTAZs.size() == 2) {
358 if (newTAZs.at(1)->getID() == value) {
363 }
else if (newTAZs.at(0) !=
TAZ) {
364 newTAZs = {
TAZ, newTAZs.at(0)};
366 }
else if (index == 1) {
367 if (newTAZs.size() == 2) {
368 if (newTAZs.at(0)->getID() == value) {
373 }
else if (newTAZs.at(0) !=
TAZ) {
374 newTAZs = {newTAZs.at(0),
TAZ};
@ DATA_SELECT
mode for selecting data elements
@ DATA_DELETE
mode for deleting data elements
@ MID_OPEN_ADDITIONAL_DIALOG
open additional dialog (used in netedit)
SumoXMLTag
Numbers representing SUMO-XML - element names.
@ SUMO_TAG_TAZ
a traffic assignment zone
@ SUMO_TAG_NOTHING
invalid tag, must be the last one
SumoXMLAttr
Numbers representing SUMO-XML - attributes.
@ SUMO_ATTR_BEGIN
weights: time range begin
@ SUMO_ATTR_END
weights: time range end
const double INVALID_DOUBLE
invalid double
std::string toString(const T &t, std::streamsize accuracy=gPrecision)
static void popMatrix()
pop matrix
static void pushMatrix()
push matrix
static void drawText(const std::string &text, const Position &pos, const double layer, const double size, const RGBColor &col=RGBColor::BLACK, const double angle=0, const int align=0, double width=-1)
const std::string getID() const
get ID (all Attribute Carriers have one)
bool isAttributeCarrierSelected() const
check if attribute carrier is selected
void selectAttributeCarrier()
select attribute carrier using GUIGlobalSelection
FXIcon * getACIcon() const
get FXIcon associated to this AC
bool mySelected
boolean to check if this AC is selected (more quickly as checking GUIGlObjectStorage)
PositionVector getCommonAttributePositionVector(SumoXMLAttr key) const
void unselectAttributeCarrier()
unselect attribute carrier using GUIGlobalSelection
const std::string & getTagStr() const
get tag assigned to this object in string format
Position getCommonAttributePosition(SumoXMLAttr key) const
GNENet * myNet
pointer to net
GNENet * getNet() const
get pointer to net
virtual void updateGeometry()=0
update pre-computed geometry information
virtual std::string getAttribute(SumoXMLAttr key) const =0
const GNETagProperties * myTagProperty
reference to tagProperty associated with this attribute carrier
double getAttributeDouble(SumoXMLAttr key) const override
GNEDataSet * getDataSetParent() const
Returns a pointer to GNEDataSet parent.
std::string getAttribute(SumoXMLAttr key) const override
std::string getFilteredAttribute() const
get filtered attribute
const AttributeSelector * getAttributeSelector() const
getattribute selector modul
Position getAttributePosition(SumoXMLAttr key) const override
bool isPathElementSelected() const override
check if path element is selected
bool checkDrawRelatedContour() const override
check if draw related contour (cyan)
bool checkDrawOverContour() const override
check if draw over contour (orange)
bool checkDrawDeleteContourSmall() const override
check if draw delete contour small (pink/white)
virtual void fixGenericDataProblem()
fix data set problem (by default throw an exception, has to be reimplemented in children)
GUIGlObject * getGUIGlObject() override
get GUIGlObject associated with this genericData
void selectGLObject() override
select element
void drawAttribute(const PositionVector &shape) const
GUIParameterTableWindow * getParameterWindow(GUIMainWindow &app, GUISUMOAbstractView &parent) override
Returns an own parameter window.
bool checkDrawDeleteContour() const override
check if draw delete contour (pink/white)
virtual std::string getGenericDataProblem() const
return a string with the current data set problem (by default empty, can be reimplemented in children...
bool checkDrawSelectContour() const override
check if draw select contour (blue)
virtual ~GNEGenericData()
Destructor.
GNEMoveElement * getMoveElement() const override
get GNEMoveElement associated with this genericData
bool checkDrawToContour() const override
check if draw from contour (magenta)
virtual Position getPositionInView() const =0
Returns element position in view.
bool checkDrawFromContour() const override
check if draw from contour (green)
GNEDataInterval * myDataIntervalParent
dataInterval Parent
std::string getPartialID() const
get partial ID
virtual bool isGenericDataValid() const
check if current data set is valid to be written into XML (by default true, can be reimplemented in c...
GNEHierarchicalElement * getHierarchicalElement() override
methods to retrieve the elements linked to this dataSet
GNEGenericData(SumoXMLTag tag, GNENet *net)
default Constructor
GUIGLObjectPopupMenu * getPopUpMenu(GUIMainWindow &app, GUISUMOAbstractView &parent) override
Returns an own popup-menu.
bool isVisibleInspectDeleteSelect() const
check if attribute is visible in inspect, delete or select mode
PositionVector getAttributePositionVector(SumoXMLAttr key) const override
GNEDataInterval * getDataIntervalParent() const
get data interval parent
void replaceFirstParentEdge(const std::string &value)
replace the first parent edge
void deleteGLObject() override
delete element
void updateGLObject() override
update GLObject (geometry, ID, etc.)
bool checkDrawMoveContour() const override
check if draw move contour (red)
void replaceParentTAZElement(const int index, const std::string &value)
replace the first parent TAZElement
void drawFilteredAttribute(const GUIVisualizationSettings &s, const PositionVector &laneShape, const std::string &attribute, const GNEDataInterval *dataIntervalParent) const
draw filtered attribute
Parameterised * getParameters() override
get parameters associated with this genericData
void replaceLastParentEdge(const std::string &value)
replace the last parent edge
const GNEHierarchicalContainerParents< GNEAdditional * > & getParentAdditionals() const
get parent additionals
const GNEHierarchicalContainerParents< GNEEdge * > & getParentEdges() const
get parent edges
static void updateParent(ElementType element, const int index, ParentType newParent)
update single parent element
static void updateParents(ElementType element, GNEHierarchicalContainerParents< ParentType > newParents)
update all parent elements
GNEAdditional * retrieveAdditional(SumoXMLTag type, const std::string &id, bool hardFail=true) const
Returns the named additional.
GNEEdge * retrieveEdge(const std::string &id, bool hardFail=true) const
get edge by id
A NBNetBuilder extended by visualisation and editing capabilities.
void deleteGenericData(GNEGenericData *genericData, GNEUndoList *undoList)
remove generic data
GNENetHelper::AttributeCarriers * getAttributeCarriers() const
get all attribute carriers used in this net
GNEViewNet * getViewNet() const
get view net
SelectionInformation * getSelectionInformation() const
get modul for selection information
SumoXMLTag getTag() const
get Tag vinculated with this attribute Property
bool hasDialog() const
return true if tag correspond to an element that can be edited using a dialog
const std::vector< const GNEAttributeProperties * > & getAttributeProperties() const
get all attribute properties
class used to group all variables related to interval bar
std::string getParameter() const
get parameter
double getBegin() const
get begin
GNEDataSet * getDataSet() const
get dataSet
double getEnd() const
get end
SumoXMLTag getGenericDataType() const
get generic data type
const GNEViewNetHelper::EditModes & getEditModes() const
get edit modes
GNEViewNetHelper::IntervalBar & getIntervalBar()
get interval bar
GNEViewParent * getViewParent() const
get the net object
bool checkOverLockedElement(const GUIGlObject *GLObject, const bool isSelected) const
check if given element is locked (used for drawing select and delete contour)
GNEUndoList * getUndoList() const
get the undoList object
GNESelectorFrame * getSelectorFrame() const
get frame for select elements
GNEEdgeDataFrame * getEdgeDataFrame() const
get frame for DATA_EDGEDATA
static FXMenuCommand * buildFXMenuCommand(FXComposite *p, const std::string &text, FXIcon *icon, FXObject *tgt, FXSelector sel, const bool disable=false)
build menu command
void buildPopUpMenuCommonOptions(GUIGLObjectPopupMenu *ret, GUIMainWindow &app, GUISUMOAbstractView *parent, const SumoXMLTag tag, const bool selected, bool addSeparator=true)
A window containing a gl-object's parameter.
void mkItem(const char *name, bool dynamic, ValueSource< T > *src)
Adds a row which obtains its value from a ValueSource.
void closeBuilding(const Parameterised *p=0)
Closes the building of the table.
GUIGLObjectPopupMenu * getPopup() const
ge the current popup-menu
Stores the information about how to visualize structures.
double getTextAngle(double objectAngle) const
return an angle that is suitable for reading text aligned with the given angle (degrees)
An upper class for objects with additional parameters.
std::map< std::string, std::string > Map
parameters map
virtual const std::string getParameter(const std::string &key, const std::string defaultValue="") const
Returns the value for a given key.
const Parameterised::Map & getParametersMap() const
Returns the inner key/value map.
A point in 2D or 3D with translation and scaling methods.
double length2D() const
Returns the length.
double length() const
Returns the length.
double rotationDegreeAtOffset(double pos) const
Returns the rotation at the given length.
Position positionAtOffset2D(double pos, double lateralOffset=0, bool extrapolateBeyond=false) const
Returns the position at the given length.
static const RGBColor BLUE
static const RGBColor BLACK