MCPcopy Create free account
hub / github.com/NPP-JSONViewer/JSON-Viewer / GetFileExtension

Method GetFileExtension

src/UtilityLib/Utility.cpp:172–184  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

170}
171
172auto CUtility::GetFileExtension(const std::wstring& fileName) -> std::wstring
173{
174 std::wstring retVal;
175
176 std::filesystem::path pathObj(fileName);
177
178 // Check if file has stem i.e. filename without extension
179 if (pathObj.has_stem())
180 {
181 retVal = pathObj.filename().extension().wstring();
182 }
183 return retVal;
184}
185
186auto CUtility::GetTempFilePath() -> std::wstring
187{

Callers 1

TESTFunction · 0.80

Calls

no outgoing calls

Tested by 1

TESTFunction · 0.64