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

Method relativeTo

source/core/StarFile_unix.cpp:106–110  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

104}
105
106String File::relativeTo(String const& relativeTo, String const& path) {
107 if (path.beginsWith("/"))
108 return path;
109 return relativeTo.trimEnd("/") + '/' + path;
110}
111
112String File::fullPath(const String& fileName) {
113 char buffer[PATH_MAX];

Callers

nothing calls this directly

Calls 2

trimEndMethod · 0.80
beginsWithMethod · 0.45

Tested by

no test coverage detected