Eclipse SUMO - Simulation of Urban MObility
GUIParkingArea.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-2020 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 // A area where vehicles can park next to the road (gui version)
19 /****************************************************************************/
20 #pragma once
21 #include <config.h>
22 
23 #include <vector>
24 #include <string>
25 #include <utils/common/Command.h>
28 #include <microsim/MSParkingArea.h>
32 #include <utils/geom/Position.h>
33 #include <gui/GUIManipulator.h>
34 
35 
36 // ===========================================================================
37 // class declarations
38 // ===========================================================================
39 class MSNet;
40 class MSLane;
41 class GUIManipulator;
42 
43 
44 // ===========================================================================
45 // class definitions
46 // ===========================================================================
59 public:
60 
73  GUIParkingArea(const std::string& id,
74  const std::vector<std::string>& lines, MSLane& lane,
75  double frompos, double topos, unsigned int capacity,
76  double width, double length, double angle, const std::string& name,
77  bool onRoad);
78 
79 
82 
83 
84 
86 
87 
96  GUISUMOAbstractView& parent);
97 
98 
109  GUISUMOAbstractView& parent);
110 
111 
118 
120  const std::string getOptionalName() const;
121 
123  void addLotEntry(double x, double y, double z,
124  double width, double length, double angle);
125 
130  void drawGL(const GUIVisualizationSettings& s) const;
132 
133 
134 private:
136  std::vector<double> myShapeRotations;
137 
139  std::vector<double> myShapeLengths;
140 
143 
145  double mySignRot;
146 
149 
150 };
A class that stores a 2D geometrical boundary.
Definition: Boundary.h:39
The popup menu of a globject.
A window containing a gl-object's parameter.
A lane area vehicles can halt at (gui-version)
std::vector< double > myShapeLengths
The lengths of the shape parts.
Boundary myBoundary
the centering boundary
std::vector< double > myShapeRotations
The rotations of the shape parts.
~GUIParkingArea()
Destructor.
void addLotEntry(double x, double y, double z, double width, double length, double angle)
extend boundary
void drawGL(const GUIVisualizationSettings &s) const
Draws the object.
double mySignRot
The rotation of the sign.
Boundary getCenteringBoundary() const
Returns the boundary to which the view shall be centered in order to show the object.
GUIParameterTableWindow * getParameterWindow(GUIMainWindow &app, GUISUMOAbstractView &parent)
Returns an own parameter window.
GUIParkingArea(const std::string &id, const std::vector< std::string > &lines, MSLane &lane, double frompos, double topos, unsigned int capacity, double width, double length, double angle, const std::string &name, bool onRoad)
Constructor.
GUIGLObjectPopupMenu * getPopUpMenu(GUIMainWindow &app, GUISUMOAbstractView &parent)
Returns an own popup-menu.
const std::string getOptionalName() const
Returns the stopping place name.
Position mySignPos
The position of the sign.
Stores the information about how to visualize structures.
Representation of a lane in the micro simulation.
Definition: MSLane.h:82
The simulated network and simulation perfomer.
Definition: MSNet.h:89
A lane area vehicles can halt at.
Definition: MSParkingArea.h:57
A point in 2D or 3D with translation and scaling methods.
Definition: Position.h:36