CARLA
 
载入中...
搜索中...
未找到
TimeoutException.cpp
浏览该文件的文档.
1s// Copyright (c) 2017 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#include "carla/client/TimeoutException.h" // 引入TimeoutException头文件
8
9namespace carla { // 定义carla命名空间
10namespace client { // 定义client子命名空间
11
12 using namespace std::string_literals; // 使用字符串字面量的命名空间
13
14 TimeoutException::TimeoutException( // TimeoutException构造函数
15 const std::string &endpoint, // 输入参数:端点地址
16 time_duration timeout) // 输入参数:超时时间
17 : std::runtime_error( // 初始化基类std::runtime_error
18 "time-out of "s + std::to_string(timeout.milliseconds()) + // 构建错误信息,包含超时时间
19 "ms while waiting for the simulator, " // 提示信息,等待模拟器时发生超时
20 "make sure the simulator is ready and connected to " + endpoint) {} // 提示用户确保模拟器已就绪并连接到指定端点
21
22} // namespace client
23} // namespace carla
24
TimeoutException(const std::string &endpoint, time_duration timeout)
构造函数。
Positive time duration up to milliseconds resolution.
Definition Time.h:19
CARLA模拟器的主命名空间。
Definition Carla.cpp:139
包含CARLA客户端相关类和函数的命名空间。