Eclipse SUMO - Simulation of Urban MObility
Loading...
Searching...
No Matches
GNECalibratorDialog Class Reference

Dialog for edit calibrators. More...

#include <GNECalibratorDialog.h>

Inheritance diagram for GNECalibratorDialog:
[legend]
Collaboration diagram for GNECalibratorDialog:
[legend]

Public Member Functions

GNEAdditionalgetEditedAdditional () const
 get edited Additional
 
 GNECalibratorDialog (GNECalibrator *editedCalibrator)
 FOX-declaration.
 
 ~GNECalibratorDialog ()
 destructor
 
FOX-callbacks

event after press accept button

long onCmdAccept (FXObject *, FXSelector, void *)
 
long onCmdCancel (FXObject *, FXSelector, void *)
 event after press cancel button
 
long onCmdReset (FXObject *, FXSelector, void *)
 event after press reset button
 
long onCmdAddRoute (FXObject *, FXSelector, void *)
 add new route
 
long onCmdClickedRoute (FXObject *, FXSelector, void *)
 remove or edit route
 
long onCmdAddFlow (FXObject *, FXSelector, void *)
 add new flow
 
long onCmdClickedFlow (FXObject *, FXSelector, void *)
 remove or edit flow
 
long onCmdAddVehicleType (FXObject *, FXSelector, void *)
 add new vehicle type
 
long onCmdClickedVehicleType (FXObject *, FXSelector, void *)
 remove or edit vehicle type
 
FOX-callbacks

event after press accept button

long onKeyPress (FXObject *sender, FXSelector sel, void *ptr)
 event after press a key
 
long onKeyRelease (FXObject *sender, FXSelector sel, void *ptr)
 event after release a key
 

Protected Member Functions

void acceptChanges ()
 Accept changes did in this dialog.
 
void cancelChanges ()
 Cancel changes did in this dialog.
 
void changeAdditionalDialogHeader (const std::string &newHeader)
 change additional dialog header
 
void initChanges ()
 init a new group of changes that will be do it in dialog
 
FXint openAsModalDialog (FXuint placement=PLACEMENT_CURSOR)
 execute dialog as modal
 
void resetChanges ()
 reset changes did in this dialog.
 

Protected Attributes

FXVerticalFrame * myContentFrame
 frame for contents
 
GNEAdditionalmyEditedAdditional
 pointer to edited additional
 
bool myUpdatingElement
 flag to indicate if additional are being created or modified (cannot be changed after open dialog)
 

Private Member Functions

 GNECalibratorDialog (const GNECalibratorDialog &)=delete
 Invalidated copy constructor.
 
GNECalibratorDialogoperator= (const GNECalibratorDialog &)=delete
 Invalidated assignment operator.
 
void updateFlowAndLabelButton ()
 update flow and label button
 
void updateFlowTable ()
 update data table with flows
 
void updateRouteTable ()
 update data table with routes
 
void updateVehicleTypeTable ()
 update data table with vehicle types
 

Private Attributes

FXButton * myAddFlow
 button for add new flow
 
FXButton * myAddRoute
 button for add new route
 
FXButton * myAddVehicleType
 button for add new vehicle type
 
FXButton * myCancelButton
 cancel button
 
std::string myChangesDescription
 description of changes did in this additional dialog
 
FXTable * myFlowList
 list with flows
 
FXButton * myKeepOldButton
 accept button
 
FXLabel * myLabelFlow
 label for flows
 
int myNumberOfChanges
 number of GNEChanges_... in dialog
 
FXButton * myResetButton
 cancel button
 
FXTable * myRouteList
 list with routes
 
FXTable * myVehicleTypeList
 list with vehicle types
 

Detailed Description

Dialog for edit calibrators.

Definition at line 43 of file GNECalibratorDialog.h.

Constructor & Destructor Documentation

◆ GNECalibratorDialog() [1/2]

◆ ~GNECalibratorDialog()

GNECalibratorDialog::~GNECalibratorDialog ( )

destructor

Definition at line 112 of file GNECalibratorDialog.cpp.

◆ GNECalibratorDialog() [2/2]

GNECalibratorDialog::GNECalibratorDialog ( const GNECalibratorDialog )
privatedelete

Invalidated copy constructor.

Member Function Documentation

◆ acceptChanges()

void GNEAdditionalDialog::acceptChanges ( )
protectedinherited

Accept changes did in this dialog.

Definition at line 123 of file GNEAdditionalDialog.cpp.

References GNEUndoList::abortLastChangeGroup(), GNEUndoList::end(), GNEAttributeCarrier::getNet(), GNEViewNet::getUndoList(), GNENet::getViewNet(), and GNEAdditionalDialog::myEditedAdditional.

Referenced by onCmdAccept(), GNECalibratorFlowDialog::onCmdAccept(), GNERerouterDialog::onCmdAccept(), GNERerouterIntervalDialog::onCmdAccept(), and GNEVariableSpeedSignDialog::onCmdAccept().

Here is the caller graph for this function:

◆ cancelChanges()

void GNEAdditionalDialog::cancelChanges ( )
protectedinherited

Cancel changes did in this dialog.

Definition at line 134 of file GNEAdditionalDialog.cpp.

References GNEUndoList::abortLastChangeGroup(), GNEAttributeCarrier::getNet(), GNEViewNet::getUndoList(), GNENet::getViewNet(), and GNEAdditionalDialog::myEditedAdditional.

Referenced by onCmdCancel(), GNECalibratorFlowDialog::onCmdCancel(), GNERerouterDialog::onCmdCancel(), GNERerouterIntervalDialog::onCmdCancel(), and GNEVariableSpeedSignDialog::onCmdCancel().

Here is the caller graph for this function:

◆ changeAdditionalDialogHeader()

void GNEAdditionalDialog::changeAdditionalDialogHeader ( const std::string &  newHeader)
protectedinherited

change additional dialog header

Definition at line 107 of file GNEAdditionalDialog.cpp.

◆ getEditedAdditional()

GNEAdditional * GNEAdditionalDialog::getEditedAdditional ( ) const
inherited

get edited Additional

Definition at line 89 of file GNEAdditionalDialog.cpp.

References GNEAdditionalDialog::myEditedAdditional.

◆ initChanges()

◆ onCmdAccept()

long GNECalibratorDialog::onCmdAccept ( FXObject *  ,
FXSelector  ,
void *   
)
virtual

Implements GNEAdditionalDialog.

Definition at line 116 of file GNECalibratorDialog.cpp.

References GNEAdditionalDialog::acceptChanges().

◆ onCmdAddFlow()

long GNECalibratorDialog::onCmdAddFlow ( FXObject *  ,
FXSelector  ,
void *   
)

add new flow

Definition at line 225 of file GNECalibratorDialog.cpp.

References GNENet::getAttributeCarriers(), GNENetHelper::AttributeCarriers::getDefaultType(), GNENetHelper::AttributeCarriers::getDemandElements(), GNEAttributeCarrier::getNet(), GNEViewNet::getNet(), GNENet::getViewNet(), GNEAdditionalDialog::myEditedAdditional, SUMO_TAG_ROUTE, TL, and updateFlowTable().

Referenced by FXDEFMAP().

Here is the caller graph for this function:

◆ onCmdAddRoute()

long GNECalibratorDialog::onCmdAddRoute ( FXObject *  ,
FXSelector  ,
void *   
)

add new route

Definition at line 148 of file GNECalibratorDialog.cpp.

References GNEAttributeCarrier::getNet(), GNEAdditionalDialog::myEditedAdditional, and updateRouteTable().

Referenced by FXDEFMAP().

Here is the caller graph for this function:

◆ onCmdAddVehicleType()

long GNECalibratorDialog::onCmdAddVehicleType ( FXObject *  ,
FXSelector  ,
void *   
)

add new vehicle type

Definition at line 266 of file GNECalibratorDialog.cpp.

References GNENetHelper::AttributeCarriers::generateDemandElementID(), GNENet::getAttributeCarriers(), GNEAttributeCarrier::getNet(), GNEViewNet::getNet(), GNENet::getViewNet(), GNEAdditionalDialog::myEditedAdditional, SUMO_TAG_VTYPE, SVC_PASSENGER, and updateVehicleTypeTable().

Referenced by FXDEFMAP().

Here is the caller graph for this function:

◆ onCmdCancel()

long GNECalibratorDialog::onCmdCancel ( FXObject *  ,
FXSelector  ,
void *   
)
virtual

event after press cancel button

Implements GNEAdditionalDialog.

Definition at line 126 of file GNECalibratorDialog.cpp.

References GNEAdditionalDialog::cancelChanges().

◆ onCmdClickedFlow()

long GNECalibratorDialog::onCmdClickedFlow ( FXObject *  ,
FXSelector  ,
void *   
)

remove or edit flow

Definition at line 243 of file GNECalibratorDialog.cpp.

References GNEUndoList::add(), GNEHierarchicalElement::getChildAdditionals(), GNEAttributeCarrier::getNet(), GNEViewNet::getUndoList(), GNENet::getViewNet(), GNEAdditionalDialog::myEditedAdditional, myFlowList, and updateFlowTable().

Referenced by FXDEFMAP().

Here is the caller graph for this function:

◆ onCmdClickedRoute()

long GNECalibratorDialog::onCmdClickedRoute ( FXObject *  ,
FXSelector  ,
void *   
)

◆ onCmdClickedVehicleType()

long GNECalibratorDialog::onCmdClickedVehicleType ( FXObject *  ,
FXSelector  ,
void *   
)

◆ onCmdReset()

long GNECalibratorDialog::onCmdReset ( FXObject *  ,
FXSelector  ,
void *   
)
virtual

event after press reset button

Implements GNEAdditionalDialog.

Definition at line 136 of file GNECalibratorDialog.cpp.

References GNEAdditionalDialog::resetChanges(), updateFlowTable(), updateRouteTable(), and updateVehicleTypeTable().

◆ onKeyPress()

long GNEAdditionalDialog::onKeyPress ( FXObject *  sender,
FXSelector  sel,
void *  ptr 
)
inherited

event after press a key

Definition at line 95 of file GNEAdditionalDialog.cpp.

Referenced by FXDEFMAP().

Here is the caller graph for this function:

◆ onKeyRelease()

long GNEAdditionalDialog::onKeyRelease ( FXObject *  sender,
FXSelector  sel,
void *  ptr 
)
inherited

event after release a key

Definition at line 101 of file GNEAdditionalDialog.cpp.

Referenced by FXDEFMAP().

Here is the caller graph for this function:

◆ openAsModalDialog()

FXint GNEAdditionalDialog::openAsModalDialog ( FXuint  placement = PLACEMENT_CURSOR)
protectedinherited

execute dialog as modal

Definition at line 76 of file GNEAdditionalDialog.cpp.

◆ operator=()

GNECalibratorDialog & GNECalibratorDialog::operator= ( const GNECalibratorDialog )
privatedelete

Invalidated assignment operator.

◆ resetChanges()

void GNEAdditionalDialog::resetChanges ( )
protectedinherited

reset changes did in this dialog.

Definition at line 140 of file GNEAdditionalDialog.cpp.

References GNEUndoList::abortLastChangeGroup(), GNEUndoList::begin(), GNEAttributeCarrier::getNet(), GNEViewNet::getUndoList(), GNENet::getViewNet(), GNEAdditionalDialog::myChangesDescription, and GNEAdditionalDialog::myEditedAdditional.

Referenced by onCmdReset(), GNECalibratorFlowDialog::onCmdReset(), GNERerouterDialog::onCmdReset(), GNERerouterIntervalDialog::onCmdReset(), and GNEVariableSpeedSignDialog::onCmdReset().

Here is the caller graph for this function:

◆ updateFlowAndLabelButton()

void GNECalibratorDialog::updateFlowAndLabelButton ( )
private

update flow and label button

Definition at line 467 of file GNECalibratorDialog.cpp.

References GNENet::getAttributeCarriers(), GNENetHelper::AttributeCarriers::getDemandElements(), GNEAttributeCarrier::getNet(), GNEViewNet::getNet(), GNENet::getViewNet(), GNE_TAG_CALIBRATOR_FLOW, myAddFlow, GNEAdditionalDialog::myEditedAdditional, myFlowList, myLabelFlow, SUMO_TAG_ROUTE, TL, and toString().

Referenced by updateFlowTable(), updateRouteTable(), and updateVehicleTypeTable().

Here is the caller graph for this function:

◆ updateFlowTable()

void GNECalibratorDialog::updateFlowTable ( )
private

update data table with flows

Definition at line 385 of file GNECalibratorDialog.cpp.

References GNEHierarchicalElement::getChildAdditionals(), GUIIconSubSys::getIcon(), GUIDesignHeight, GNEAdditionalDialog::myEditedAdditional, myFlowList, REMOVE, SUMO_ATTR_ROUTE, SUMO_ATTR_TYPE, SUMO_ATTR_VCLASS, toString(), and updateFlowAndLabelButton().

Referenced by onCmdAddFlow(), onCmdClickedFlow(), onCmdClickedRoute(), onCmdClickedVehicleType(), and onCmdReset().

Here is the caller graph for this function:

◆ updateRouteTable()

void GNECalibratorDialog::updateRouteTable ( )
private

update data table with routes

Definition at line 346 of file GNECalibratorDialog.cpp.

References GNENet::getAttributeCarriers(), GNENetHelper::AttributeCarriers::getDemandElements(), GUIIconSubSys::getIcon(), GNEAttributeCarrier::getNet(), GNEViewNet::getNet(), GNENet::getViewNet(), GUIDesignHeight, GNEAdditionalDialog::myEditedAdditional, myRouteList, REMOVE, SUMO_ATTR_EDGES, SUMO_ATTR_ID, SUMO_TAG_ROUTE, toString(), and updateFlowAndLabelButton().

Referenced by onCmdAddRoute(), onCmdClickedRoute(), and onCmdReset().

Here is the caller graph for this function:

◆ updateVehicleTypeTable()

void GNECalibratorDialog::updateVehicleTypeTable ( )
private

update data table with vehicle types

Definition at line 424 of file GNECalibratorDialog.cpp.

References GNENet::getAttributeCarriers(), GNENetHelper::AttributeCarriers::getDemandElements(), GUIIconSubSys::getIcon(), GNEAttributeCarrier::getNet(), GNEViewNet::getNet(), GNENet::getViewNet(), GUIDesignHeight, GNEAdditionalDialog::myEditedAdditional, myVehicleTypeList, REMOVE, SUMO_ATTR_ID, SUMO_ATTR_VCLASS, SUMO_TAG_VTYPE, toString(), and updateFlowAndLabelButton().

Referenced by onCmdAddVehicleType(), onCmdClickedVehicleType(), and onCmdReset().

Here is the caller graph for this function:

Field Documentation

◆ myAddFlow

FXButton* GNECalibratorDialog::myAddFlow
private

button for add new flow

Definition at line 98 of file GNECalibratorDialog.h.

Referenced by updateFlowAndLabelButton().

◆ myAddRoute

FXButton* GNECalibratorDialog::myAddRoute
private

button for add new route

Definition at line 89 of file GNECalibratorDialog.h.

◆ myAddVehicleType

FXButton* GNECalibratorDialog::myAddVehicleType
private

button for add new vehicle type

Definition at line 104 of file GNECalibratorDialog.h.

◆ myCancelButton

FXButton* GNEAdditionalDialog::myCancelButton
privateinherited

cancel button

Definition at line 110 of file GNEAdditionalDialog.h.

◆ myChangesDescription

std::string GNEAdditionalDialog::myChangesDescription
privateinherited

description of changes did in this additional dialog

Definition at line 116 of file GNEAdditionalDialog.h.

Referenced by GNEAdditionalDialog::initChanges(), and GNEAdditionalDialog::resetChanges().

◆ myContentFrame

FXVerticalFrame* GNEAdditionalDialog::myContentFrame
protectedinherited

frame for contents

Definition at line 85 of file GNEAdditionalDialog.h.

◆ myEditedAdditional

GNEAdditional* GNEAdditionalDialog::myEditedAdditional
protectedinherited

pointer to edited additional

Definition at line 79 of file GNEAdditionalDialog.h.

Referenced by GNEAdditionalDialog::acceptChanges(), GNEAdditionalDialog::cancelChanges(), GNEAdditionalDialog::getEditedAdditional(), GNEAdditionalDialog::initChanges(), GNECalibratorFlowDialog::onCmdAccept(), GNERerouterDialog::onCmdAccept(), GNERerouterIntervalDialog::onCmdAccept(), GNERerouterIntervalDialog::onCmdAddClosingLaneReroute(), GNERerouterIntervalDialog::onCmdAddClosingReroute(), GNERerouterIntervalDialog::onCmdAddDestProbReroute(), onCmdAddFlow(), GNERerouterIntervalDialog::onCmdAddParkingAreaReroute(), onCmdAddRoute(), GNERerouterIntervalDialog::onCmdAddRouteProbReroute(), GNEVariableSpeedSignDialog::onCmdAddStep(), onCmdAddVehicleType(), GNERerouterIntervalDialog::onCmdChangeBeginEnd(), GNERerouterIntervalDialog::onCmdClickedClosingLaneReroute(), GNERerouterIntervalDialog::onCmdClickedClosingReroute(), GNERerouterIntervalDialog::onCmdClickedDestProbReroute(), onCmdClickedFlow(), GNERerouterDialog::onCmdClickedInterval(), GNERerouterIntervalDialog::onCmdClickedParkingAreaReroute(), onCmdClickedRoute(), GNERerouterIntervalDialog::onCmdClickedRouteProbReroute(), GNEVariableSpeedSignDialog::onCmdClickedStep(), onCmdClickedVehicleType(), GNERerouterIntervalDialog::onCmdEditClosingLaneReroute(), GNERerouterIntervalDialog::onCmdEditClosingReroute(), GNERerouterIntervalDialog::onCmdEditDestProbReroute(), GNERerouterIntervalDialog::onCmdEditParkingAreaReroute(), GNERerouterIntervalDialog::onCmdEditRouteProbReroute(), GNEVariableSpeedSignDialog::onCmdEditStep(), GNECalibratorFlowDialog::onCmdSetVariable(), GNEAdditionalDialog::resetChanges(), GNECalibratorFlowDialog::updateCalibratorFlowValues(), updateFlowAndLabelButton(), updateFlowTable(), GNERerouterDialog::updateIntervalTable(), updateRouteTable(), GNEVariableSpeedSignDialog::updateTableSteps(), and updateVehicleTypeTable().

◆ myFlowList

FXTable* GNECalibratorDialog::myFlowList
private

list with flows

Definition at line 101 of file GNECalibratorDialog.h.

Referenced by onCmdClickedFlow(), updateFlowAndLabelButton(), and updateFlowTable().

◆ myKeepOldButton

FXButton* GNEAdditionalDialog::myKeepOldButton
privateinherited

accept button

Definition at line 107 of file GNEAdditionalDialog.h.

◆ myLabelFlow

FXLabel* GNECalibratorDialog::myLabelFlow
private

label for flows

Definition at line 95 of file GNECalibratorDialog.h.

Referenced by updateFlowAndLabelButton().

◆ myNumberOfChanges

int GNEAdditionalDialog::myNumberOfChanges
privateinherited

number of GNEChanges_... in dialog

Definition at line 119 of file GNEAdditionalDialog.h.

Referenced by GNEAdditionalDialog::initChanges().

◆ myResetButton

FXButton* GNEAdditionalDialog::myResetButton
privateinherited

cancel button

Definition at line 113 of file GNEAdditionalDialog.h.

◆ myRouteList

FXTable* GNECalibratorDialog::myRouteList
private

list with routes

Definition at line 92 of file GNECalibratorDialog.h.

Referenced by onCmdClickedRoute(), and updateRouteTable().

◆ myUpdatingElement

bool GNEAdditionalDialog::myUpdatingElement
protectedinherited

flag to indicate if additional are being created or modified (cannot be changed after open dialog)

Definition at line 82 of file GNEAdditionalDialog.h.

Referenced by GNECalibratorFlowDialog::onCmdAccept(), and GNERerouterIntervalDialog::onCmdAccept().

◆ myVehicleTypeList

FXTable* GNECalibratorDialog::myVehicleTypeList
private

list with vehicle types

Definition at line 107 of file GNECalibratorDialog.h.

Referenced by onCmdClickedVehicleType(), and updateVehicleTypeTable().


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