Eclipse SUMO - Simulation of Urban MObility
GNEVehicleFrame.h
Go to the documentation of this file.
1 /****************************************************************************/
2 // Eclipse SUMO, Simulation of Urban MObility; see https://eclipse.dev/sumo
3 // Copyright (C) 2001-2024 German Aerospace Center (DLR) and others.
4 // This program and the accompanying materials are made available under the
5 // terms of the Eclipse Public License 2.0 which is available at
6 // https://www.eclipse.org/legal/epl-2.0/
7 // This Source Code may also be made available under the following Secondary
8 // Licenses when the conditions for such availability set forth in the Eclipse
9 // Public License 2.0 are satisfied: GNU General Public License, version 2
10 // or later which is available at
11 // https://www.gnu.org/licenses/old-licenses/gpl-2.0-standalone.html
12 // SPDX-License-Identifier: EPL-2.0 OR GPL-2.0-or-later
13 /****************************************************************************/
18 // The Widget for add Vehicles/Flows/Trips/etc. elements
19 /****************************************************************************/
20 #pragma once
21 #include <config.h>
22 
29 
30 // ===========================================================================
31 // class declaration
32 // ===========================================================================
33 
34 class MFXDynamicLabel;
35 
36 // ===========================================================================
37 // class definitions
38 // ===========================================================================
42 class GNEVehicleFrame : public GNEFrame {
43 
44 public:
45 
46  // ===========================================================================
47  // class HelpCreation
48  // ===========================================================================
49 
51 
52  public:
54  HelpCreation(GNEVehicleFrame* vehicleFrameParent);
55 
57  ~HelpCreation();
58 
60  void showHelpCreation();
61 
63  void hideHelpCreation();
64 
66  void updateHelpCreation();
67 
68  private:
71 
74  };
75 
80  GNEVehicleFrame(GNEViewParent* viewParent, GNEViewNet* viewNet);
81 
84 
86  void show();
87 
89  void hide();
90 
96  bool addVehicle(const GNEViewNetHelper::ViewObjectsSelector& viewObjects, const GNEViewNetHelper::MouseButtonKeyPressed& mouseButtonKeyPressed);
97 
100 
103 
106 
109 
110 protected:
112  void tagSelected();
113 
115  void demandElementSelected();
116 
118  bool createPath(const bool useLastRoute);
119 
121  bool buildVehicleOverRoute(SumoXMLTag vehicleTag, GNEDemandElement* route);
122 
123 private:
126 
129 
132 
135 
138 
141 
144 
147 };
SumoXMLTag
Numbers representing SUMO-XML - element names.
Builds trigger objects for GNENet (busStops, chargingStations, detectors, etc..)
void showHelpCreation()
show HelpCreation
MFXDynamicLabel * myInformationLabel
Label with creation information.
void hideHelpCreation()
hide HelpCreation
void updateHelpCreation()
update HelpCreation
GNEVehicleFrame * myVehicleFrameParent
pointer to Vehicle Frame Parent
HelpCreation(GNEVehicleFrame *vehicleFrameParent)
constructor
GNEAttributesCreator * myVehicleAttributes
internal vehicle attributes
GNETagSelector * myVehicleTagSelector
vehicle tag selector (used to select diffent kind of vehicles)
void hide()
hide Frame
GNEPathCreator * getPathCreator() const
get GNEPathCreator module
GNERouteHandler myRouteHandler
route handler
GNEDemandElementSelector * myTypeSelector
Vehicle Type selectors.
bool createPath(const bool useLastRoute)
create path
CommonXMLStructure::SumoBaseObject * myVehicleBaseObject
vehicle base object
GNEAttributesCreator * getVehicleAttributes() const
get attributes creator
~GNEVehicleFrame()
Destructor.
void show()
show Frame
GNEPathCreator * myPathCreator
edge path creator (used for trips and flows)
bool buildVehicleOverRoute(SumoXMLTag vehicleTag, GNEDemandElement *route)
build vehicle over route
GNEDemandElementSelector * getTypeSelector() const
getVehicle Type selectors
void tagSelected()
Tag selected in GNETagSelector.
HelpCreation * myHelpCreation
Help creation.
GNEVehicleFrame(GNEViewParent *viewParent, GNEViewNet *viewNet)
Constructor.
void demandElementSelected()
selected vehicle type in DemandElementSelector
GNEPathLegendModule * myPathLegend
path legend modul
bool addVehicle(const GNEViewNetHelper::ViewObjectsSelector &viewObjects, const GNEViewNetHelper::MouseButtonKeyPressed &mouseButtonKeyPressed)
add vehicle element
GNETagSelector * getVehicleTagSelector() const
get vehicle tag selector (needed for transform vehicles)
class used to group all variables related with objects under cursor after a click over view
A single child window which contains a view of the simulation area.
Definition: GNEViewParent.h:88
A list item which allows for custom coloring.
MFXGroupBoxModule (based on FXGroupBox)
class used to group all variables related with mouse buttons and key pressed after certain events