Eclipse SUMO - Simulation of Urban MObility
GNEChange_DemandElement.h
Go to the documentation of this file.
1 /****************************************************************************/
2 // Eclipse SUMO, Simulation of Urban MObility; see https://eclipse.org/sumo
3 // Copyright (C) 2001-2019 German Aerospace Center (DLR) and others.
4 // This program and the accompanying materials
5 // are made available under the terms of the Eclipse Public License v2.0
6 // which accompanies this distribution, and is available at
7 // http://www.eclipse.org/legal/epl-v20.html
8 // SPDX-License-Identifier: EPL-2.0
9 /****************************************************************************/
15 // A network change in which a demand element element is created or deleted
16 /****************************************************************************/
17 #ifndef GNEChange_DemandElement_h
18 #define GNEChange_DemandElement_h
19 
20 // ===========================================================================
21 // included modules
22 // ===========================================================================
23 #include <config.h>
24 
25 #include "GNEChange.h"
26 
27 // ===========================================================================
28 // class declarations
29 // ===========================================================================
30 
31 class GNEViewNet;
32 class GNEEdge;
33 class GNELane;
34 class GNEShape;
35 class GNEAdditional;
36 class GNEDemandElement;
37 class GNEXMLChild;
38 
39 // ===========================================================================
40 // class definitions
41 // ===========================================================================
47  FXDECLARE_ABSTRACT(GNEChange_DemandElement)
48 
49 public:
54  GNEChange_DemandElement(GNEDemandElement* demandElement, bool forward);
55 
58 
62  FXString undoName() const;
63 
65  FXString redoName() const;
66 
68  void undo();
69 
71  void redo();
73 
74 private:
79 
81  const std::vector<GNEEdge*>& myEdgeParents;
82 
84  const std::vector<GNELane*>& myLaneParents;
85 
87  const std::vector<GNEShape*>& myShapeParents;
88 
90  const std::vector<GNEAdditional*>& myAdditionalParents;
91 
93  const std::vector<GNEDemandElement*>& myDemandElementParents;
94 
96  const std::vector<GNEEdge*>& myEdgeChildren;
97 
99  const std::vector<GNELane*>& myLaneChildren;
100 
102  const std::vector<GNEShape*>& myShapeChildren;
103 
105  const std::vector<GNEAdditional*>& myAdditionalChildren;
106 
108  const std::vector<GNEDemandElement*>& myDemandElementChildren;
109 };
110 
111 #endif
112 /****************************************************************************/
const std::vector< GNEAdditional * > & myAdditionalChildren
reference to vector of additional children
the function-object for an editing operation (abstract base)
Definition: GNEChange.h:43
const std::vector< GNEAdditional * > & myAdditionalParents
reference to vector of additional parents
const std::vector< GNEShape * > & myShapeChildren
reference to vector of shape children
const std::vector< GNEEdge * > & myEdgeParents
reference to vector of edge parents
This lane is powered by an underlying GNEEdge and basically knows how to draw itself.
Definition: GNELane.h:46
const std::vector< GNEDemandElement * > & myDemandElementParents
reference to vector of demand element parents
const std::vector< GNELane * > & myLaneChildren
reference to vector of lane children
const std::vector< GNELane * > & myLaneParents
reference to vector of lane parents
const std::vector< GNEDemandElement * > & myDemandElementChildren
reference to vector of demand element children
FXString undoName() const
return undoName
const std::vector< GNEShape * > & myShapeParents
reference to vector of shape parents
const std::vector< GNEEdge * > & myEdgeChildren
reference to vector of edge children
A road/street connecting two junctions (netedit-version)
Definition: GNEEdge.h:50
An Element which don&#39;t belongs to GNENet but has influency in the simulation.
Definition: GNEAdditional.h:47
FXString redoName() const
get Redo name
GNEChange_DemandElement(GNEDemandElement *demandElement, bool forward)
Constructor for creating/deleting an demand element element.
GNEDemandElement * myDemandElement
full information regarding the demand element element that is to be created/deleted ...
An Element which don&#39;t belongs to GNENet but has influency in the simulation.