| 124 | } |
| 125 | |
| 126 | Status ValidateAbstractPathParts(const std::vector<std::string>& parts) { |
| 127 | for (const auto& part : parts) { |
| 128 | if (part.length() == 0) { |
| 129 | return Status::Invalid("Empty path component"); |
| 130 | } |
| 131 | if (part.find_first_of(kSep) != std::string::npos) { |
| 132 | return Status::Invalid("Separator in component '", part, "'"); |
| 133 | } |
| 134 | } |
| 135 | return Status::OK(); |
| 136 | } |
| 137 | |
| 138 | Status ValidateAbstractPath(std::string_view path) { |
| 139 | auto pos = path.find_first_of(kSep); |