Apollo  6.0
Open source self driving car software
obu_interface_abstract_class.h
Go to the documentation of this file.
1 /******************************************************************************
2  * Copyright 2018 The Apollo Authors. All Rights Reserved.
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  *****************************************************************************/
16 
22 #pragma once
23 
24 #include <chrono>
25 #include <memory>
26 
27 #include "modules/perception/proto/traffic_light_detection.pb.h"
28 #include "modules/v2x/proto/v2x_car_status.pb.h"
29 #include "modules/v2x/proto/v2x_obstacles.pb.h"
30 #include "modules/v2x/proto/v2x_obu_rsi.pb.h"
31 #include "modules/v2x/proto/v2x_traffic_light.pb.h"
32 
33 #include "cyber/cyber.h"
34 
35 namespace apollo {
36 namespace v2x {
37 
39  public:
41 
42  virtual ~ObuInterFaceBase() {}
43 
44  public:
45  virtual bool InitialServer() = 0;
46 
47  virtual bool InitialClient() = 0;
48 
50  std::shared_ptr<::apollo::v2x::obu::ObuTrafficLight> *msg) {}
51 
52  virtual void SendCarStatusToObu(
53  const std::shared_ptr<::apollo::v2x::CarStatus> &msg) {}
54 
55  virtual void GetV2xRsiFromObu(
56  std::shared_ptr<::apollo::v2x::obu::ObuRsi> *msg) {}
57  virtual void GetV2xObstaclesFromObu(
58  std::shared_ptr<::apollo::v2x::V2XObstacles> *msg) {}
59 };
60 
61 } // namespace v2x
62 } // namespace apollo
PlanningContext is the runtime context in planning. It is persistent across multiple frames...
Definition: atomic_hash_map.h:25
virtual void GetV2xObstaclesFromObu(std::shared_ptr<::apollo::v2x::V2XObstacles > *msg)
Definition: obu_interface_abstract_class.h:57
virtual void GetV2xRsiFromObu(std::shared_ptr<::apollo::v2x::obu::ObuRsi > *msg)
Definition: obu_interface_abstract_class.h:55
ObuInterFaceBase()
Definition: obu_interface_abstract_class.h:40
virtual bool InitialClient()=0
virtual void GetV2xTrafficLightFromObu(std::shared_ptr<::apollo::v2x::obu::ObuTrafficLight > *msg)
Definition: obu_interface_abstract_class.h:49
Definition: obu_interface_abstract_class.h:38
virtual ~ObuInterFaceBase()
Definition: obu_interface_abstract_class.h:42
virtual void SendCarStatusToObu(const std::shared_ptr<::apollo::v2x::CarStatus > &msg)
Definition: obu_interface_abstract_class.h:52
virtual bool InitialServer()=0