![]() |
Eclipse SUMO - Simulation of Urban MObility
|
#include <GNEChange_DemandElement.h>
Public Member Functions | |
GNEChange_DemandElement (GNEDemandElement *demandElement, bool forward) | |
Constructor for creating/deleting an demand element element. More... | |
virtual FXuint | size () const |
return actual size More... | |
~GNEChange_DemandElement () | |
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 | |
const std::vector< GNEAdditional * > & | myChildAdditionals |
reference to vector of child additional More... | |
const std::vector< GNEDemandElement * > & | myChildDemandElements |
reference to vector of child demand elements More... | |
const std::vector< GNEEdge * > & | myChildEdges |
reference to vector of child edges More... | |
const std::vector< GNELane * > & | myChildLanes |
reference to vector of child lanes More... | |
const std::vector< GNEShape * > & | myChildShapes |
reference to vector of child shapes More... | |
GNEDemandElement * | myDemandElement |
full information regarding the demand element element that is to be created/deleted More... | |
const std::vector< GNEEdge * > & | myEdgePath |
reference to edge path vector More... | |
const std::vector< GNEAdditional * > & | myParentAdditionals |
reference to vector of parent additionals More... | |
const std::vector< GNEDemandElement * > & | myParentDemandElements |
reference to vector of parent demand elements More... | |
const std::vector< GNEEdge * > & | myParentEdges |
reference to vector of parent edges More... | |
const std::vector< GNELane * > & | myParentLanes |
reference to vector of parent lanes More... | |
const std::vector< GNEShape * > & | myParentShapes |
reference to vector of parent shapes More... | |
A network change in which a demand element element is created or deleted
Definition at line 45 of file GNEChange_DemandElement.h.
GNEChange_DemandElement::GNEChange_DemandElement | ( | GNEDemandElement * | demandElement, |
bool | forward | ||
) |
Constructor for creating/deleting an demand element element.
[in] | demand | element The demand element element to be created/deleted |
[in] | forward | Whether to create/delete (true/false) |
Definition at line 43 of file GNEChange_DemandElement.cpp.
GNEChange_DemandElement::~GNEChange_DemandElement | ( | ) |
Destructor.
Definition at line 61 of file GNEChange_DemandElement.cpp.
References GNEReferenceCounter::decRef(), GNENet::deleteDemandElement(), GNENet::demandElementExist(), GNEAttributeCarrier::getID(), GNEAttributeCarrier::getTagStr(), myChildAdditionals, myChildDemandElements, myChildEdges, myChildLanes, myChildShapes, myDemandElement, myEdgePath, GNEChange::myNet, myParentAdditionals, myParentDemandElements, myParentEdges, myParentLanes, myParentShapes, GNEReferenceCounter::unreferenced(), and WRITE_DEBUG.
|
virtual |
redo action
Reimplemented from GNEChange.
Definition at line 203 of file GNEChange_DemandElement.cpp.
References GNENet::deleteDemandElement(), GNEAttributeCarrier::getID(), GNEAttributeCarrier::TagProperties::getTag(), GNEAttributeCarrier::getTagProperty(), GNEAttributeCarrier::getTagStr(), GNEViewParent::getVehicleTypeFrame(), GNEVehicleTypeFrame::getVehicleTypeSelector(), GNENet::getViewNet(), GNEViewNet::getViewParent(), GNENet::insertDemandElement(), myChildAdditionals, myChildDemandElements, myChildEdges, myChildLanes, myChildShapes, myDemandElement, myEdgePath, GNEChange::myForward, GNEChange::myNet, myParentAdditionals, myParentDemandElements, myParentEdges, myParentLanes, myParentShapes, GNEVehicleTypeFrame::VehicleTypeSelector::refreshVehicleTypeSelector(), GNENet::requireSaveDemandElements(), SUMO_TAG_VTYPE, and WRITE_DEBUG.
|
virtual |
get Redo name
Reimplemented from GNEChange.
Definition at line 303 of file GNEChange_DemandElement.cpp.
References GNEAttributeCarrier::getTagStr(), myDemandElement, and GNEChange::myForward.
|
virtualinherited |
return actual size
Definition at line 44 of file GNEChange.cpp.
|
virtual |
undo action
Reimplemented from GNEChange.
Definition at line 113 of file GNEChange_DemandElement.cpp.
References GNENet::deleteDemandElement(), GNEAttributeCarrier::getID(), GNEAttributeCarrier::TagProperties::getTag(), GNEAttributeCarrier::getTagProperty(), GNEAttributeCarrier::getTagStr(), GNEViewParent::getVehicleTypeFrame(), GNEVehicleTypeFrame::getVehicleTypeSelector(), GNENet::getViewNet(), GNEViewNet::getViewParent(), GNENet::insertDemandElement(), myChildAdditionals, myChildDemandElements, myChildEdges, myChildLanes, myChildShapes, myDemandElement, myEdgePath, GNEChange::myForward, GNEChange::myNet, myParentAdditionals, myParentDemandElements, myParentEdges, myParentLanes, myParentShapes, GNEVehicleTypeFrame::VehicleTypeSelector::refreshVehicleTypeSelector(), GNENet::requireSaveDemandElements(), SUMO_TAG_VTYPE, and WRITE_DEBUG.
|
virtual |
return undoName
Reimplemented from GNEChange.
Definition at line 293 of file GNEChange_DemandElement.cpp.
References GNEAttributeCarrier::getTagStr(), myDemandElement, and GNEChange::myForward.
|
private |
reference to vector of child additional
Definition at line 107 of file GNEChange_DemandElement.h.
Referenced by redo(), undo(), and ~GNEChange_DemandElement().
|
private |
reference to vector of child demand elements
Definition at line 110 of file GNEChange_DemandElement.h.
Referenced by redo(), undo(), and ~GNEChange_DemandElement().
|
private |
reference to vector of child edges
Definition at line 98 of file GNEChange_DemandElement.h.
Referenced by redo(), undo(), and ~GNEChange_DemandElement().
|
private |
reference to vector of child lanes
Definition at line 101 of file GNEChange_DemandElement.h.
Referenced by redo(), undo(), and ~GNEChange_DemandElement().
|
private |
reference to vector of child shapes
Definition at line 104 of file GNEChange_DemandElement.h.
Referenced by redo(), undo(), and ~GNEChange_DemandElement().
|
private |
full information regarding the demand element element that is to be created/deleted
Definition at line 77 of file GNEChange_DemandElement.h.
Referenced by redo(), redoName(), undo(), undoName(), and ~GNEChange_DemandElement().
|
private |
reference to edge path vector
Definition at line 80 of file GNEChange_DemandElement.h.
Referenced by redo(), undo(), and ~GNEChange_DemandElement().
|
protectedinherited |
we group antagonistic commands (create junction/delete junction) and keep them apart by this flag
Definition at line 80 of file GNEChange.h.
Referenced by GNEChange_Additional::redo(), GNEChange_Children::redo(), GNEChange_Connection::redo(), GNEChange_Crossing::redo(), redo(), GNEChange_Edge::redo(), GNEChange_Junction::redo(), GNEChange_Lane::redo(), GNEChange_Shape::redo(), GNEChange_TLS::redo(), GNEChange_Additional::redoName(), GNEChange_Children::redoName(), GNEChange_Connection::redoName(), GNEChange_Crossing::redoName(), redoName(), GNEChange_Edge::redoName(), GNEChange_Junction::redoName(), GNEChange_Lane::redoName(), GNEChange_Shape::redoName(), GNEChange_TLS::redoName(), GNEChange_Additional::undo(), GNEChange_Children::undo(), GNEChange_Connection::undo(), GNEChange_Crossing::undo(), undo(), GNEChange_Edge::undo(), GNEChange_Junction::undo(), GNEChange_Lane::undo(), GNEChange_Shape::undo(), GNEChange_TLS::undo(), GNEChange_Additional::undoName(), GNEChange_Children::undoName(), GNEChange_Connection::undoName(), GNEChange_Crossing::undoName(), undoName(), GNEChange_Edge::undoName(), GNEChange_Junction::undoName(), GNEChange_Lane::undoName(), GNEChange_Shape::undoName(), and GNEChange_TLS::undoName().
|
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 75 of file GNEChange.h.
Referenced by GNEChange_Crossing::GNEChange_Crossing(), GNEChange_Additional::redo(), GNEChange_Attribute::redo(), GNEChange_Children::redo(), GNEChange_Connection::redo(), GNEChange_Crossing::redo(), redo(), GNEChange_Edge::redo(), GNEChange_EnableAttribute::redo(), GNEChange_Junction::redo(), GNEChange_Lane::redo(), GNEChange_Shape::redo(), GNEChange_TLS::redo(), GNEChange_Additional::undo(), GNEChange_Attribute::undo(), GNEChange_Children::undo(), GNEChange_Connection::undo(), GNEChange_Crossing::undo(), undo(), GNEChange_Edge::undo(), GNEChange_EnableAttribute::undo(), GNEChange_Junction::undo(), GNEChange_Lane::undo(), GNEChange_Shape::undo(), GNEChange_TLS::undo(), GNEChange_Additional::~GNEChange_Additional(), GNEChange_Attribute::~GNEChange_Attribute(), GNEChange_Crossing::~GNEChange_Crossing(), ~GNEChange_DemandElement(), GNEChange_EnableAttribute::~GNEChange_EnableAttribute(), and GNEChange_Shape::~GNEChange_Shape().
|
private |
reference to vector of parent additionals
Definition at line 92 of file GNEChange_DemandElement.h.
Referenced by redo(), undo(), and ~GNEChange_DemandElement().
|
private |
reference to vector of parent demand elements
Definition at line 95 of file GNEChange_DemandElement.h.
Referenced by redo(), undo(), and ~GNEChange_DemandElement().
|
private |
reference to vector of parent edges
Definition at line 83 of file GNEChange_DemandElement.h.
Referenced by redo(), undo(), and ~GNEChange_DemandElement().
|
private |
reference to vector of parent lanes
Definition at line 86 of file GNEChange_DemandElement.h.
Referenced by redo(), undo(), and ~GNEChange_DemandElement().
|
private |
reference to vector of parent shapes
Definition at line 89 of file GNEChange_DemandElement.h.
Referenced by redo(), undo(), and ~GNEChange_DemandElement().