std::experimental::filesystem::path::has_...
来自cppreference.com
< cpp | experimental | fs | path
bool has_root_path() const; | (1) | (文件系统 TS) |
bool has_root_name() const; | (2) | (文件系统 TS) |
bool has_root_directory() const; | (3) | (文件系统 TS) |
bool has_relative_path() const; | (4) | (文件系统 TS) |
bool has_parent_path() const; | (5) | (文件系统 TS) |
bool has_filename() const; | (6) | (文件系统 TS) |
bool has_stem() const; | (7) | (文件系统 TS) |
bool has_extension() const; | (8) | (文件系统 TS) |
检查路径是否包含对应的路径元素。
1) 检查 root_path() 是否为空。
2) 检查 root_name() 是否为空。
3) 检查 root_directory() 是否为空。
4) 检查 relative_path() 是否为空。
5) 检查 parent_path() 是否为空。
6) 检查 filename() 是否为空。
7) 检查 stem() 是否为空。
8) 检查 extension() 是否为空。
参数
(无)
返回值
若对应路径非空则为 true,否则为 false。
异常
可能会抛出由实现定义的异常。
参阅
检查路径是否为空 (公开成员函数) |