| 179 | } |
| 180 | |
| 181 | void ModuleResourceContainer::FindNodes(const std::string& path, const std::string& filePattern, |
| 182 | bool recurse, std::vector<ModuleResource>& resources) const |
| 183 | { |
| 184 | std::vector<std::string> names; |
| 185 | std::vector<uint32_t> indices; |
| 186 | |
| 187 | this->GetChildren(path, true, names, indices); |
| 188 | |
| 189 | for(std::size_t i = 0, s = names.size(); i < s; ++i) |
| 190 | { |
| 191 | if (*names[i].rbegin() == '/' && recurse) |
| 192 | { |
| 193 | this->FindNodes(path + names[i], filePattern, recurse, resources); |
| 194 | } |
| 195 | if (this->Matches(names[i], filePattern)) |
| 196 | { |
| 197 | resources.push_back(ModuleResource(indices[i], *this)); |
| 198 | } |
| 199 | } |
| 200 | } |
| 201 | |
| 202 | bool ModuleResourceContainer::Matches(const std::string& name, const std::string& filePattern) |
| 203 | { |
no test coverage detected