55 GNEChange(additional->getViewNet()->getNet(), forward),
56 myAdditional(additional),
61 myAdditional->incRef(
"GNEChange_Additional");
63 if (myAdditional->getLane() != NULL) {
64 myLaneParent = myAdditional->getLane();
67 if (myAdditional->getEdge() != NULL) {
68 myEdgeParent = myAdditional->getEdge();
78 myE3Parent =
dynamic_cast<GNEDetectorExit*
>(myAdditional)->getE3Parent();
82 myEdgeChilds =
dynamic_cast<GNERerouter*
>(myAdditional)->getEdgeChilds();
123 (*i)->getLane()->removeAdditionalChild(*i);
128 (*i)->getLane()->removeAdditionalChild(*i);
150 (*i)->removeGNERerouter(rerouter);
174 (*i)->getLane()->addAdditionalChild(*i);
179 (*i)->getLane()->addAdditionalChild(*i);
201 (*i)->addGNERerouter(rerouter);
231 (*i)->getLane()->addAdditionalChild(*i);
236 (*i)->getLane()->addAdditionalChild(*i);
258 (*i)->addGNERerouter(rerouter);
281 (*i)->getLane()->removeAdditionalChild(*i);
286 (*i)->getLane()->removeAdditionalChild(*i);
308 (*i)->removeGNERerouter(rerouter);
GNEEdge * myEdgeParent
pointer to edge (used by additionals with edge parent)
GNELane * getLane() const
get lane of additional, or NULL if additional isn't placed over a Lane
the function-object for an editing operation (abstract base)
FXString redoName() const
get Redo name
std::vector< GNEDetectorEntry * > myEntryChilds
list of Entry detectors child (used by E3 Detector)
void addExitChild(GNEDetectorExit *exit)
add an Exit child
void removeAdditionalChild(GNEAdditional *additional)
remove additional child to this lane
std::vector< GNEEdge * > myEdgeChilds
list of Edge childs (used by Rerouters)
std::vector< GNEDetectorEntry * > myGNEDetectorEntrys
vector with the GNEDetectorE3EntryExits of the detector
~GNEChange_Additional()
Destructor.
#define WRITE_WARNING(msg)
bool isTestingModeEnabled() const
check if netedit is running in testing mode
FXString undoName() const
return undoName
GNEAdditional * myAdditional
full information regarding the additional element that is to be created/deleted
void addAdditionalChild(GNEAdditional *additional)
add additional child to this edge
std::string toString(const T &t, std::streamsize accuracy=gPrecision)
void updateGeometry()
update pre-computed geometry information
void addAdditionalChild(GNEAdditional *additional)
add additional child to this lane
std::vector< GNEDetectorExit * > myGNEDetectorExits
vector with the GNEDetectorE3EntryExits of the detector
std::vector< GNEDetectorExit * > myExitChilds
list of Exit detectors child used (used by E3 Detector)
const std::string getID() const
function to support debugging
void decRef(const std::string &debugMsg="")
GNENet * myNet
the net to which operations shall be applied or which shall be informed about gui updates (we are not...
An Element which don't belongs to GNENet but has influency in the simulation.
GNEDetectorE3 * myE3Parent
pointer to E3 parent (used by Entry/exits)
bool myForward
we group antagonistic commands (create junction/delete junction) and keep them apart by this flag ...
void deleteAdditional(GNEAdditional *additional)
delete additional element previously inserted
void addEntryChild(GNEDetectorEntry *entry)
add an Entry child
void removeEntryChild(GNEDetectorEntry *entry)
delete an Entry child
void removeAdditionalChild(GNEAdditional *additional)
remove additional child from this edge
void removeExitChild(GNEDetectorExit *exit)
delete an Exit child
GNELane * myLaneParent
pointer to lane (used by additionals with lane parent)
void insertAdditional(GNEAdditional *additional, bool hardFail=true)
Insert a additional element previously created in GNEAdditionalHandler.
GNEEdge * getEdge() const
get edge of additional, or NULL if additional isn't placed over an edge
GNEViewNet * getViewNet() const
get view net
SumoXMLTag getTag() const
get XML Tag assigned to this object