MCPcopy Create free account
hub / github.com/Exiv2/exiv2 / newFilePath

Function newFilePath

app/actions.cpp:1949–1957  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1947}
1948
1949std::string newFilePath(const std::string& path, const std::string& ext) {
1950 auto p = fs::path(path);
1951 auto directory = fs::path(Params::instance().directory_);
1952 if (directory.empty())
1953 directory = p.parent_path();
1954 if (Exiv2::fileProtocol(path) != Exiv2::pFile)
1955 directory.clear(); // use current directory for remote files
1956 return (directory / (p.stem().string() + ext)).string();
1957}
1958
1959int dontOverwrite(const std::string& path) {
1960 if (path == "-")

Callers 5

runMethod · 0.85
writeThumbnailMethod · 0.85
writePreviewFileMethod · 0.85
insertIccProfileMethod · 0.85
insertThumbnailMethod · 0.85

Calls 4

pathFunction · 0.85
fileProtocolFunction · 0.85
emptyMethod · 0.45
clearMethod · 0.45

Tested by

no test coverage detected