File indexing completed on 2025-01-30 09:35:37
0001
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012
0013
0014 #ifndef BOOST_FILESYSTEM_CONVENIENCE_HPP
0015 #define BOOST_FILESYSTEM_CONVENIENCE_HPP
0016
0017 #include <boost/filesystem/config.hpp>
0018 #include <boost/filesystem/operations.hpp>
0019 #include <boost/system/error_code.hpp>
0020
0021 #include <boost/filesystem/detail/header.hpp> // must be the last #include
0022
0023 namespace boost {
0024 namespace filesystem {
0025
0026 #ifndef BOOST_FILESYSTEM_NO_DEPRECATED
0027
0028 BOOST_FILESYSTEM_DETAIL_DEPRECATED("Use path::extension() instead")
0029 inline std::string extension(const path& p)
0030 {
0031 return p.extension().string();
0032 }
0033
0034 BOOST_FILESYSTEM_DETAIL_DEPRECATED("Use path::stem() instead")
0035 inline std::string basename(const path& p)
0036 {
0037 return p.stem().string();
0038 }
0039
0040 BOOST_FILESYSTEM_DETAIL_DEPRECATED("Use path::replace_extension() instead")
0041 inline path change_extension(const path& p, const path& new_extension)
0042 {
0043 path new_p(p);
0044 new_p.replace_extension(new_extension);
0045 return new_p;
0046 }
0047
0048 #endif
0049
0050 }
0051 }
0052
0053 #include <boost/filesystem/detail/footer.hpp>
0054
0055 #endif