MCPcopy Create free account
hub / github.com/NazaraEngine/NazaraEngine / NormalizePath

Method NormalizePath

src/Nazara/Core/File.cpp:714–725  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

712 */
713
714 String File::NormalizePath(const String& filePath)
715 {
716 String path = NormalizeSeparators(filePath.Trimmed());
717
718 if (!IsAbsolute(path))
719 path = Directory::GetCurrent() + NAZARA_DIRECTORY_SEPARATOR + path;
720
721 while (path.EndsWith(NAZARA_DIRECTORY_SEPARATOR))
722 path.Resize(-1);
723
724 return path;
725 }
726
727 /*!
728 * \brief Normalizes the path separator

Callers

nothing calls this directly

Calls 3

TrimmedMethod · 0.80
EndsWithMethod · 0.80
ResizeMethod · 0.45

Tested by

no test coverage detected