MCPcopy Create free account
hub / github.com/SakuraEngine/SakuraEngine / get_file

Method get_file

modules/gui/gui/src/backend/text_server/ustring.cpp:5474–5483  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

5472}
5473
5474String String::get_file() const
5475{
5476 int sep = MAX(rfind("/"), rfind("\\"));
5477 if (sep == -1)
5478 {
5479 return *this;
5480 }
5481
5482 return substr(sep + 1, length());
5483}
5484
5485String String::get_extension() const
5486{

Callers 1

path_to_fileMethod · 0.80

Calls 2

substrFunction · 0.85
lengthFunction · 0.50

Tested by

no test coverage detected