CARLA
Controller.h
Go to the documentation of this file.
1 // Copyright (c) 2020 Computer Vision Center (CVC) at the Universitat Autonoma
2 // de Barcelona (UAB).
3 //
4 // This work is licensed under the terms of the MIT license.
5 // For a copy; see <https://opensource.org/licenses/MIT>.
6 
7 #pragma once
8 
9 #include "carla/NonCopyable.h"
10 #include "carla/road/RoadTypes.h"
11 
12 #include <set>
13 
14 namespace carla {
15 namespace road {
16 
17  class MapBuilder;
18 
19  class Controller : private MovableNonCopyable {
20 
21  public:
22 
24  ContId id,
25  std::string name,
26  uint32_t sequence)
27  : _id(id),
28  _name(name),
29  _sequence(sequence){}
30 
31  const ContId& GetControllerId() const{
32  return _id;
33  }
34 
35  const std::string& GetName() const {
36  return _name;
37  }
38 
39  const uint32_t &GetSequence() const {
40  return _sequence;
41  }
42 
43  const std::set<SignId>& GetSignals() const {
44  return _signals;
45  }
46 
47  const std::set<JuncId>& GetJunctions() const {
48  return _junctions;
49  }
50 
51  private:
52 
53  friend MapBuilder;
54 
56  std::string _name;
57  uint32_t _sequence;
58 
59  std::set<JuncId> _junctions;
60  std::set<SignId> _signals;
61  };
62 
63 } // namespace road
64 } // namespace carla
const std::set< SignId > & GetSignals() const
Definition: Controller.h:43
std::set< JuncId > _junctions
Definition: Controller.h:59
Controller(ContId id, std::string name, uint32_t sequence)
Definition: Controller.h:23
This file contains definitions of common data structures used in traffic manager. ...
Definition: Carla.cpp:133
Inherit (privately) to suppress copy construction and assignment.
const std::set< JuncId > & GetJunctions() const
Definition: Controller.h:47
const ContId & GetControllerId() const
Definition: Controller.h:31
std::set< SignId > _signals
Definition: Controller.h:60
const uint32_t & GetSequence() const
Definition: Controller.h:39
std::string ContId
Definition: RoadTypes.h:29
const std::string & GetName() const
Definition: Controller.h:35