SUMO - Simulation of Urban MObility
NBSign.h
Go to the documentation of this file.
1 /****************************************************************************/
8 // A class representing a street sign
9 /****************************************************************************/
10 // SUMO, Simulation of Urban MObility; see http://sumo.dlr.de/
11 // Copyright (C) 2012-2015 DLR (http://www.dlr.de/) and contributors
12 /****************************************************************************/
13 //
14 // This file is part of SUMO.
15 // SUMO is free software: you can redistribute it and/or modify
16 // it under the terms of the GNU General Public License as published by
17 // the Free Software Foundation, either version 3 of the License, or
18 // (at your option) any later version.
19 //
20 /****************************************************************************/
21 #ifndef NBSign_h
22 #define NBSign_h
23 
24 
25 // ===========================================================================
26 // included modules
27 // ===========================================================================
28 #ifdef _MSC_VER
29 #include <windows_config.h>
30 #else
31 #include <config.h>
32 #endif
33 
34 #include <string>
36 
37 // ===========================================================================
38 // class declarations
39 // ===========================================================================
40 class NBEdge;
41 class OutputDevice;
42 
43 
44 // ===========================================================================
45 // class definitions
46 // ===========================================================================
51 class NBSign {
52 public:
53 
54  enum SignType {
66  SIGN_TYPE_INFO // terminator
67  };
68 
75  NBSign(SignType type, SUMOReal offset, const std::string label = "");
76 
77 
79  ~NBSign();
80 
82  void writeAsPOI(OutputDevice& into, const NBEdge* edge) const;
83 
84 
85 private:
88 
91 
93  std::string myLabel;
94 
97 };
98 
99 
100 #endif
101 
102 /****************************************************************************/
103 
A class representing a single street sign.
Definition: NBSign.h:51
SUMOReal myOffset
The offset of the sign from the start of its edge.
Definition: NBSign.h:90
The representation of a single edge during network building.
Definition: NBEdge.h:70
void writeAsPOI(OutputDevice &into, const NBEdge *edge) const
write into device as POI positioned relative to the given edge
Definition: NBSign.cpp:82
~NBSign()
Destructor.
Definition: NBSign.cpp:78
static StringBijection< SignType > SignTypeColors
Definition: NBSign.h:96
std::string myLabel
The (optional) label (for SPEED, SLOPE etc)
Definition: NBSign.h:93
NBSign(SignType type, SUMOReal offset, const std::string label="")
Constructor with id, and position.
Definition: NBSign.cpp:71
static StringBijection< SignType > SignTypeStrings
Definition: NBSign.h:95
SignType myType
the type of the sign
Definition: NBSign.h:87
Static storage of an output device and its base (abstract) implementation.
Definition: OutputDevice.h:71
#define SUMOReal
Definition: config.h:214
SignType
Definition: NBSign.h:54