MCPcopy Create free account
hub / github.com/clechasseur/pathcopycopy / GetPath

Method GetPath

PathCopyCopy/plugins/src/SambaPathPlugin.cpp:66–78  ·  view source on GitHub ↗

Returns the path of the specified file in Samba format @param p_File File path. @return Samba path.

Source from the content-addressed store, hash-verified

64 // @return Samba path.
65 //
66 std::wstring SambaPathPlugin::GetPath(const std::wstring& p_File) const
67 {
68 // First call inherited version to get the Internet path.
69 std::wstring path = InternetPathPlugin::GetPath(p_File);
70
71 // The Internet path plugin did almost all the job for us.
72 // All we have to do is replace the prefix.
73 if (path.find(FILE_URI_PREFIX) == 0) {
74 path = SAMBA_URI_PREFIX + path.replace(0, ::wcslen(FILE_URI_PREFIX), L"");
75 }
76
77 return path;
78 }
79
80 } // namespace Plugins
81

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected