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

Function dir_exists

utility/glob.cpp:262–273  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

260}
261
262bool dir_exists(const String &path, bool include_hidden = false) {
263 String basename = get_file_name(path);
264 Ref<DirAccess> da = DirAccess::open(get_real_base_dir(path));
265 if (da.is_null()) {
266 return false;
267 }
268 da->set_include_hidden(include_hidden);
269 if ((da->dir_exists(basename))) {
270 return true;
271 }
272 return false;
273}
274
275bool dir_or_file_exists(const String &path, bool include_hidden = false) {
276 String basename = get_file_name(path);

Callers 2

glob0Function · 0.85
_globMethod · 0.85

Calls 3

get_file_nameFunction · 0.85
get_real_base_dirFunction · 0.85
dir_existsMethod · 0.80

Tested by

no test coverage detected