Apollo 11.0
自动驾驶开放平台
path_decision.h
浏览该文件的文档.
1/******************************************************************************
2 * Copyright 2017 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
21#pragma once
22
23#include <limits>
24#include <string>
25
26#include "modules/common_msgs/planning_msgs/decision.pb.h"
27
30
31namespace apollo {
32namespace planning {
33
40 public:
41 PathDecision() = default;
42
43 Obstacle *AddObstacle(const Obstacle &obstacle);
44
46
47 bool AddLateralDecision(const std::string &tag, const std::string &object_id,
48 const ObjectDecisionType &decision);
49 bool AddLongitudinalDecision(const std::string &tag,
50 const std::string &object_id,
51 const ObjectDecisionType &decision);
52
53 const Obstacle *Find(const std::string &object_id) const;
54
56 const std::string &perception_obstacle_id) const;
57
58 Obstacle *Find(const std::string &object_id);
59
60 void SetSTBoundary(const std::string &id, const STBoundary &boundary);
61 void EraseStBoundaries();
62 MainStop main_stop() const { return main_stop_; }
63 double stop_reference_line_s() const { return stop_reference_line_s_; }
64 bool MergeWithMainStop(const ObjectStop &obj_stop, const std::string &obj_id,
65 const ReferenceLine &ref_line,
66 const SLBoundary &adc_sl_boundary);
67
68 private:
70 MainStop main_stop_;
71 double stop_reference_line_s_ = std::numeric_limits<double>::max();
72};
73
74} // namespace planning
75} // namespace apollo
This is the class that associates an Obstacle with its path properties.
Definition obstacle.h:62
PathDecision represents all obstacle decisions on one path.
void SetSTBoundary(const std::string &id, const STBoundary &boundary)
const Obstacle * Find(const std::string &object_id) const
const IndexedList< std::string, Obstacle > & obstacles() const
bool MergeWithMainStop(const ObjectStop &obj_stop, const std::string &obj_id, const ReferenceLine &ref_line, const SLBoundary &adc_sl_boundary)
bool AddLateralDecision(const std::string &tag, const std::string &object_id, const ObjectDecisionType &decision)
bool AddLongitudinalDecision(const std::string &tag, const std::string &object_id, const ObjectDecisionType &decision)
Obstacle * AddObstacle(const Obstacle &obstacle)
const perception::PerceptionObstacle * FindPerceptionObstacle(const std::string &perception_obstacle_id) const
Planning module main class.
class register implement
Definition arena_queue.h:37