MCPcopy Create free account
hub / github.com/OpenStarbound/OpenStarbound / fullPath

Method fullPath

source/core/StarFile_windows.cpp:78–91  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

76}
77
78String File::fullPath(const String& path) {
79 WCHAR buffer[MAX_PATH];
80
81 size_t fullpath_size;
82 WCHAR* lpszLastNamePart;
83
84 fullpath_size = GetFullPathNameW(stringToUtf16(path).get(), (DWORD)MAX_PATH, buffer, (WCHAR**)&lpszLastNamePart);
85 if (0 == fullpath_size)
86 throw IOException::format("GetFullPathName failed on path: '{}'", path);
87 if (fullpath_size >= MAX_PATH)
88 throw IOException::format("GetFullPathName failed on path: '{}'", path);
89
90 return utf16ToString(buffer);
91}
92
93List<std::pair<String, bool>> File::dirList(const String& dirName, bool skipDots) {
94 List<std::pair<String, bool>> fileList;

Callers

nothing calls this directly

Calls 4

stringToUtf16Function · 0.85
utf16ToStringFunction · 0.85
formatFunction · 0.70
getMethod · 0.45

Tested by

no test coverage detected