Eclipse SUMO - Simulation of Urban MObility
GNEChange_EnableAttribute.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 /****************************************************************************/
14 // A network change in which the attribute of some object is modified
15 /****************************************************************************/
16 #ifndef GNEChange_EnableAttribute_h
17 #define GNEChange_EnableAttribute_h
18 
19 
20 // ===========================================================================
21 // included modules
22 // ===========================================================================
23 #include <config.h>
24 
25 #include "GNEChange.h"
26 
27 // ===========================================================================
28 // class declarations
29 // ===========================================================================
31 class GNENetElement;
32 class GNEAdditional;
33 class GNEDemandElement;
34 class GNEShape;
35 class GNENet;
36 
37 // ===========================================================================
38 // class definitions
39 // ===========================================================================
45  FXDECLARE_ABSTRACT(GNEChange_EnableAttribute)
46 
47 public:
54  GNEChange_EnableAttribute(GNEAttributeCarrier* ac, GNENet* net, const int originalAttributes, const int newAttributes);
55 
58 
62  FXString undoName() const;
63 
65  FXString redoName() const;
66 
68  void undo();
69 
71  void redo();
73 
74 private:
79 
82 
84  const int myNewAttributes;
85 };
86 
87 #endif
88 /****************************************************************************/
GNEDemandElement
An Element which don't belongs to GNENet but has influency in the simulation.
Definition: GNEDemandElement.h:55
GNEAdditional
An Element which don't belongs to GNENet but has influency in the simulation.
Definition: GNEAdditional.h:48
GNEChange_EnableAttribute::redoName
FXString redoName() const
get Redo name
Definition: GNEChange_EnableAttribute.cpp:108
GNEChange_EnableAttribute::redo
void redo()
redo action
Definition: GNEChange_EnableAttribute.cpp:85
GNENet
A NBNetBuilder extended by visualisation and editing capabilities.
Definition: GNENet.h:77
GNEChange.h
GNEChange_EnableAttribute::undoName
FXString undoName() const
return undoName
Definition: GNEChange_EnableAttribute.cpp:102
GNEChange_EnableAttribute::myOriginalAttributes
const int myOriginalAttributes
original attributes
Definition: GNEChange_EnableAttribute.h:81
GNEShape
Definition: GNEShape.h:34
GNEChange_EnableAttribute::GNEChange_EnableAttribute
GNEChange_EnableAttribute(GNEAttributeCarrier *ac, GNENet *net, const int originalAttributes, const int newAttributes)
Constructor.
Definition: GNEChange_EnableAttribute.cpp:36
GNEChange_EnableAttribute::~GNEChange_EnableAttribute
~GNEChange_EnableAttribute()
Destructor.
Definition: GNEChange_EnableAttribute.cpp:45
GNEChange_EnableAttribute
the function-object for an editing operation (abstract base)
Definition: GNEChange_EnableAttribute.h:44
GNENetElement
Definition: GNENetElement.h:43
GNEChange_EnableAttribute::myAC
GNEAttributeCarrier * myAC
the net to which all operations shall be applied
Definition: GNEChange_EnableAttribute.h:78
GNEChange_EnableAttribute::undo
void undo()
undo action
Definition: GNEChange_EnableAttribute.cpp:68
GNEChange_EnableAttribute::myNewAttributes
const int myNewAttributes
original attributes
Definition: GNEChange_EnableAttribute.h:84
config.h
GNEChange
the function-object for an editing operation (abstract base)
Definition: GNEChange.h:42
GNEAttributeCarrier
Definition: GNEAttributeCarrier.h:54