![]() |
SUMO - Simulation of Urban MObility
|
#include <GNEChange_Lane.h>
Public Member Functions | |
GNEChange_Lane (GNEEdge *edge, GNELane *lane, const NBEdge::Lane &laneAttrs, bool forward) | |
Constructor for creating/deleting an edge. More... | |
virtual FXuint | size () const |
return actual size More... | |
~GNEChange_Lane () | |
Destructor. More... | |
inherited from GNEChange | |
get undo Name | |
FXString | undoName () const |
return undoName More... | |
FXString | redoName () const |
get Redo name More... | |
void | undo () |
undo action More... | |
void | redo () |
redo action More... | |
Protected Attributes | |
bool | myForward |
we group antagonistic commands (create junction/delete junction) and keep them apart by this flag More... | |
GNENet * | myNet |
the net to which operations shall be applied or which shall be informed about gui updates (we are not responsible for the pointer) More... | |
Private Attributes | |
std::vector< GNEAdditional * > | myAdditionalChilds |
we need to preserve the list of additionals vinculated with this lane More... | |
std::vector< GNEAdditional * > | myAdditionalParents |
we need to preserve the list of additional sets in which this lane is a child More... | |
GNEEdge * | myEdge |
we need the edge because it is the target of our change commands More... | |
GNELane * | myLane |
we need to preserve the lane because it maybe the target of GNEChange_Attribute commands More... | |
const NBEdge::Lane | myLaneAttrs |
we need to preserve the attributes explicitly because they are not contained withing GNELane itself More... | |
std::vector< GNEShape * > | myShapeChilds |
we need to preserve the list of shapes vinculated with this lane More... | |
A network change in which a single lane is created or deleted
Definition at line 52 of file GNEChange_Lane.h.
GNEChange_Lane::GNEChange_Lane | ( | GNEEdge * | edge, |
GNELane * | lane, | ||
const NBEdge::Lane & | laneAttrs, | ||
bool | forward | ||
) |
Constructor for creating/deleting an edge.
constructor for creating an edge
[in] | edge | The edge on which to apply changes |
[in] | lane | The lane to be deleted or 0 if a lane should be created |
[in] | laneAttrs | The attributes of the lane to be created/deleted |
[in] | forward | Whether to create/delete (true/false) |
Definition at line 50 of file GNEChange_Lane.cpp.
GNEChange_Lane::~GNEChange_Lane | ( | ) |
Destructor.
Definition at line 70 of file GNEChange_Lane.cpp.
References GNEReferenceCounter::decRef(), OptionsCont::getBool(), GNEAttributeCarrier::getID(), OptionsCont::getOptions(), GNEAttributeCarrier::getTag(), myEdge, myLane, toString(), GNEReferenceCounter::unreferenced(), and WRITE_WARNING.
|
virtual |
redo action
Reimplemented from GNEChange.
Definition at line 138 of file GNEChange_Lane.cpp.
References GNEEdge::addLane(), GNENet::deleteAdditional(), GNEAttributeCarrier::getID(), OptionsCont::getOptions(), GNEAttributeCarrier::getTag(), GNENet::insertAdditional(), myAdditionalChilds, myEdge, GNEChange::myForward, myLane, myLaneAttrs, GNEChange::myNet, myShapeChilds, GNEEdge::removeLane(), GNENet::removeShape(), SUMO_TAG_EDGE, SUMO_TAG_LANE, toString(), and WRITE_WARNING.
|
virtual |
get Redo name
Reimplemented from GNEChange.
Definition at line 192 of file GNEChange_Lane.cpp.
References GNEChange::myForward, SUMO_TAG_LANE, and toString().
|
virtualinherited |
return actual size
Definition at line 52 of file GNEChange.cpp.
|
virtual |
undo action
Reimplemented from GNEChange.
Definition at line 94 of file GNEChange_Lane.cpp.
References GNEEdge::addLane(), GNENet::deleteAdditional(), GNEAttributeCarrier::getID(), OptionsCont::getOptions(), GNEAttributeCarrier::getTag(), GNENet::insertAdditional(), myAdditionalChilds, myEdge, GNEChange::myForward, myLane, myLaneAttrs, GNEChange::myNet, myShapeChilds, GNEEdge::removeLane(), GNENet::removeShape(), SUMO_TAG_EDGE, SUMO_TAG_LANE, toString(), and WRITE_WARNING.
|
virtual |
return undoName
Reimplemented from GNEChange.
Definition at line 182 of file GNEChange_Lane.cpp.
References GNEChange::myForward, SUMO_TAG_LANE, and toString().
|
private |
we need to preserve the list of additionals vinculated with this lane
Definition at line 94 of file GNEChange_Lane.h.
|
private |
we need to preserve the list of additional sets in which this lane is a child
Definition at line 100 of file GNEChange_Lane.h.
|
private |
we need the edge because it is the target of our change commands
Definition at line 85 of file GNEChange_Lane.h.
Referenced by redo(), undo(), and ~GNEChange_Lane().
|
protectedinherited |
we group antagonistic commands (create junction/delete junction) and keep them apart by this flag
Definition at line 86 of file GNEChange.h.
Referenced by GNEChange_Junction::redo(), GNEChange_Shape::redo(), GNEChange_Selection::redo(), GNEChange_TLS::redo(), GNEChange_VariableSpeedSignItem::redo(), GNEChange_Connection::redo(), redo(), GNEChange_Additional::redo(), GNEChange_Edge::redo(), GNEChange_Crossing::redo(), GNEChange_CalibratorItem::redo(), GNEChange_RerouterItem::redo(), GNEChange_Shape::redoName(), GNEChange_Junction::redoName(), GNEChange_Selection::redoName(), GNEChange_TLS::redoName(), GNEChange_Additional::redoName(), GNEChange_Connection::redoName(), redoName(), GNEChange_Edge::redoName(), GNEChange_Crossing::redoName(), GNEChange_Shape::undo(), GNEChange_Junction::undo(), GNEChange_Selection::undo(), GNEChange_TLS::undo(), GNEChange_VariableSpeedSignItem::undo(), GNEChange_Connection::undo(), undo(), GNEChange_Additional::undo(), GNEChange_Edge::undo(), GNEChange_Crossing::undo(), GNEChange_CalibratorItem::undo(), GNEChange_RerouterItem::undo(), GNEChange_Shape::undoName(), GNEChange_Junction::undoName(), GNEChange_Selection::undoName(), GNEChange_TLS::undoName(), GNEChange_Connection::undoName(), undoName(), GNEChange_Additional::undoName(), GNEChange_Edge::undoName(), and GNEChange_Crossing::undoName().
|
private |
we need to preserve the lane because it maybe the target of GNEChange_Attribute commands
Definition at line 88 of file GNEChange_Lane.h.
Referenced by redo(), undo(), and ~GNEChange_Lane().
|
private |
we need to preserve the attributes explicitly because they are not contained withing GNELane itself
Definition at line 91 of file GNEChange_Lane.h.
|
protectedinherited |
the net to which operations shall be applied or which shall be informed about gui updates (we are not responsible for the pointer)
Definition at line 81 of file GNEChange.h.
Referenced by GNEChange_Junction::redo(), GNEChange_Shape::redo(), GNEChange_Selection::redo(), GNEChange_VariableSpeedSignItem::redo(), GNEChange_Additional::redo(), redo(), GNEChange_Edge::redo(), GNEChange_Crossing::redo(), GNEChange_CalibratorItem::redo(), GNEChange_RerouterItem::redo(), GNEChange_Shape::undo(), GNEChange_Junction::undo(), GNEChange_Selection::undo(), GNEChange_VariableSpeedSignItem::undo(), GNEChange_Additional::undo(), undo(), GNEChange_Edge::undo(), GNEChange_Crossing::undo(), GNEChange_CalibratorItem::undo(), GNEChange_RerouterItem::undo(), GNEChange_Additional::~GNEChange_Additional(), GNEChange_CalibratorItem::~GNEChange_CalibratorItem(), GNEChange_Crossing::~GNEChange_Crossing(), and GNEChange_Shape::~GNEChange_Shape().
|
private |
we need to preserve the list of shapes vinculated with this lane
Definition at line 97 of file GNEChange_Lane.h.