MCPcopy Create free account
hub / github.com/GDRETools/gdsdecomp / glob1

Function glob1

utility/glob.cpp:366–377  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

364// takes a literal basename (so it only has to check for its existence).
365
366Vector<String> glob1(const String &dirname, const String &pattern,
367 bool dironly, bool include_hidden) {
368 // std::cout << "In glob1\n";
369 auto names = iter_directory(dirname, dironly, include_hidden);
370 Vector<String> filtered_names;
371 for (auto &n : names) {
372 if (!is_hidden(n) || include_hidden) {
373 filtered_names.push_back(get_file_name(n));
374 }
375 }
376 return filter(filtered_names, pattern);
377}
378
379Vector<String> glob0(const String &dirname, const String &basename,
380 bool dironly, bool include_hidden) {

Callers 1

_globMethod · 0.85

Calls 5

iter_directoryFunction · 0.85
is_hiddenFunction · 0.85
get_file_nameFunction · 0.85
filterFunction · 0.85
push_backMethod · 0.80

Tested by

no test coverage detected