Eclipse SUMO - Simulation of Urban MObility
GNEChange_TLS.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 traffic light is created or deleted
16
/****************************************************************************/
17
#ifndef GNEChange_TLS_h
18
#define GNEChange_TLS_h
19
20
21
// ===========================================================================
22
// included modules
23
// ===========================================================================
24
#include <
config.h
>
25
26
#include <fx.h>
27
#include <
utils/foxtools/fxexdefs.h
>
28
#include "
GNEChange.h
"
29
30
// ===========================================================================
31
// class declarations
32
// ===========================================================================
33
class
NBTrafficLightDefinition
;
34
class
GNEJunction
;
35
36
// ===========================================================================
37
// class definitions
38
// ===========================================================================
43
class
GNEChange_TLS
:
public
GNEChange
{
44
FXDECLARE_ABSTRACT(
GNEChange_TLS
)
45
46
public
:
53
GNEChange_TLS
(
GNEJunction
* junction,
NBTrafficLightDefinition
* tlDef,
bool
forward,
bool
forceInsert =
false
,
const
std::string tlID =
""
);
54
56
~GNEChange_TLS
();
57
61
FXString
undoName
()
const
;
62
64
FXString
redoName
()
const
;
65
67
void
undo
();
68
70
void
redo
();
72
73
74
private
:
78
GNEJunction
*
myJunction
;
79
83
NBTrafficLightDefinition
*
myTlDef
;
84
86
bool
myForceInsert
;
87
};
88
89
#endif
90
/****************************************************************************/
GNEChange_TLS::redoName
FXString redoName() const
get Redo name
Definition:
GNEChange_TLS.cpp:117
fxexdefs.h
GNEChange_TLS::myJunction
GNEJunction * myJunction
we need the junction because it is the target of our change commands
Definition:
GNEChange_TLS.h:78
GNEChange.h
GNEChange_TLS::GNEChange_TLS
GNEChange_TLS(GNEJunction *junction, NBTrafficLightDefinition *tlDef, bool forward, bool forceInsert=false, const std::string tlID="")
Constructor for creating/deleting an edge.
Definition:
GNEChange_TLS.cpp:43
GNEChange_TLS::myTlDef
NBTrafficLightDefinition * myTlDef
the traffic light to be created/deleted. We assume no responsiblity for the pointer
Definition:
GNEChange_TLS.h:83
GNEChange_TLS
Definition:
GNEChange_TLS.h:43
GNEChange_TLS::myForceInsert
bool myForceInsert
check if forceInsert is enabled
Definition:
GNEChange_TLS.h:86
GNEChange_TLS::redo
void redo()
redo action
Definition:
GNEChange_TLS.cpp:89
config.h
GNEChange_TLS::~GNEChange_TLS
~GNEChange_TLS()
Destructor.
Definition:
GNEChange_TLS.cpp:59
GNEChange_TLS::undoName
FXString undoName() const
return undoName
Definition:
GNEChange_TLS.cpp:107
GNEJunction
Definition:
GNEJunction.h:48
GNEChange_TLS::undo
void undo()
undo action
Definition:
GNEChange_TLS.cpp:71
GNEChange
the function-object for an editing operation (abstract base)
Definition:
GNEChange.h:43
NBTrafficLightDefinition
The base class for traffic light logic definitions.
Definition:
NBTrafficLightDefinition.h:68
src
netedit
changes
GNEChange_TLS.h
Generated on Wed Jan 15 2020 15:04:13 for Eclipse SUMO - Simulation of Urban MObility by
1.8.16