SUMO - Simulation of Urban MObility
GNEChange_Edge Class Reference

#include <GNEChange_Edge.h>

Inheritance diagram for GNEChange_Edge:
Inheritance graph
Collaboration diagram for GNEChange_Edge:
Collaboration graph

Public Member Functions

 GNEChange_Edge (GNENet *net, GNEEdge *edge, bool forward)
 Constructor for creating/deleting an edge. More...
 
void redo ()
 
FXString redoName () const
 
virtual FXuint size () const
 
void undo ()
 
FXString undoName () const
 
 ~GNEChange_Edge ()
 Destructor. More...
 

Protected Attributes

bool myForward
 we group antagonistic commands (create junction/delete junction) and keep them apart by this flag More...
 
GNENetmyNet
 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

GNEEdgemyEdge
 full information regarding the edge that is to be created/deleted we assume shared responsibility for the pointer (via reference counting) More...
 

Detailed Description

A network change in which a single edge is created or deleted

Definition at line 49 of file GNEChange_Edge.h.

Constructor & Destructor Documentation

GNEChange_Edge::GNEChange_Edge ( GNENet net,
GNEEdge edge,
bool  forward 
)

Constructor for creating/deleting an edge.

Parameters
[in]netThe net on which to apply changes
[in]edgeThe edge to be created/deleted
[in]forwardWhether to create/delete (true/false)

Definition at line 50 of file GNEChange_Edge.cpp.

GNEChange_Edge::~GNEChange_Edge ( )

Destructor.

Definition at line 58 of file GNEChange_Edge.cpp.

References GNEReferenceCounter::decRef(), myEdge, and GNEReferenceCounter::unreferenced().

Member Function Documentation

void GNEChange_Edge::redo ( )
virtual
FXString GNEChange_Edge::redoName ( ) const
virtual

Reimplemented from GNEChange.

Definition at line 94 of file GNEChange_Edge.cpp.

References GNEChange::myForward.

virtual FXuint GNEChange::size ( ) const
inlinevirtualinherited

Definition at line 62 of file GNEChange.h.

void GNEChange_Edge::undo ( )
virtual
FXString GNEChange_Edge::undoName ( ) const
virtual

Reimplemented from GNEChange.

Definition at line 85 of file GNEChange_Edge.cpp.

References GNEChange::myForward.

Field Documentation

GNEEdge* GNEChange_Edge::myEdge
private

full information regarding the edge that is to be created/deleted we assume shared responsibility for the pointer (via reference counting)

Definition at line 73 of file GNEChange_Edge.h.

Referenced by redo(), undo(), and ~GNEChange_Edge().

GNENet* GNEChange::myNet
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 73 of file GNEChange.h.

Referenced by redo(), GNEChange_Junction::redo(), GNEChange::redo(), GNEChange_Junction::undo(), and undo().


The documentation for this class was generated from the following files: