CARLA
 
载入中...
搜索中...
未找到
静态 Public 成员函数 | 所有成员列表
carla::FileSystem类 参考

用于访问文件系统的静态函数。 更多...

#include <FileSystem.h>

静态 Public 成员函数

static std::vector< std::string > ListFolder (const std::string &folder_path, const std::string &wildcard_pattern)
 列出 folder_path 中匹配 wildcard_pattern 的常规文件 (不递归)。
 
static void ValidateFilePath (std::string &filepath, const std::string &default_extension="")
 在创建文件之前验证路径的方便函数。
 

详细描述

用于访问文件系统的静态函数。

警告
使用此文件需要链接 boost_filesystem。

在文件 FileSystem.h17 行定义.

成员函数说明

◆ ListFolder()

std::vector< std::string > carla::FileSystem::ListFolder ( const std::string & folder_path,
const std::string & wildcard_pattern )
static

列出 folder_path 中匹配 wildcard_pattern 的常规文件 (不递归)。

异常
std::invalid_argument如果文件夹不存在。
待办事项
进行权限检查。

在文件 FileSystem.cpp46 行定义.

引用了 end(), carla::StringUtil::Match() , 以及 carla::throw_exception().

被这些函数引用 util::OpenDrive::GetAvailableFiles().

+ 函数调用图:
+ 这是这个函数的调用关系图:

◆ ValidateFilePath()

void carla::FileSystem::ValidateFilePath ( std::string & filepath,
const std::string & default_extension = "" )
static

在创建文件之前验证路径的方便函数。

1) 确保所有缺失的父目录被创建。 2) 如果 filepath 缺少扩展名,则将 default_extension 附加到路径上。

在文件 FileSystem.cpp27 行定义.

被这些函数引用 carla::pointcloud::PointCloudIO::SaveToDisk() , 以及 carla::client::FileTransfer::WriteFile().

+ 这是这个函数的调用关系图:

该类的文档由以下文件生成: