Apollo 10.0
自动驾驶开放平台
driver_base.h
浏览该文件的文档.
1/******************************************************************************
2 * Copyright 2020 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 <cstdint>
25#include <cstring>
26#include <memory>
27#include <sstream>
28#include <string>
29#include <vector>
30
31#include "cyber/common/log.h"
32#include "cyber/cyber.h"
37namespace apollo {
38namespace drivers {
39namespace lidar {
40
46 public:
51 explicit LidarDriver(const std::shared_ptr<::apollo::cyber::Node>& node)
52 : node_(node) {}
53
57 virtual ~LidarDriver() = default;
58
63 virtual bool Init() = 0;
64
65 protected:
66 std::shared_ptr<cyber::Node> node_;
67};
68
69} // namespace lidar
70} // namespace drivers
71} // namespace apollo
The class which defines the lidar driver .
Definition driver_base.h:45
std::shared_ptr< cyber::Node > node_
Definition driver_base.h:66
virtual ~LidarDriver()=default
Destructor
virtual bool Init()=0
Initialize the lidar driver.
LidarDriver(const std::shared_ptr<::apollo::cyber::Node > &node)
Definition driver_base.h:51
class register implement
Definition arena_queue.h:37