23 #ifndef OST_BOOST_FILESYSTEM_HELPER_HH
24 #define OST_BOOST_FILESYSTEM_HELPER_HH
26 #include <boost/filesystem/path.hpp>
27 #include <boost/version.hpp>
32 String BFPathToString(
const boost::filesystem::path& path)
34 #if BOOST_FILESYSTEM_VERSION==3 || BOOST_VERSION<103400
37 return path.file_string();
41 inline String BFPathStem(
const boost::filesystem::path& path) {
42 #if BOOST_FILESYSTEM_VERSION<103400
43 String name = BFPathToString(path);
44 size_t n = name.rfind(
'.');
45 return name.substr(0, n);