Boost  v1.57.0
doxygen for www.boost.org
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
boost::filesystem Namespace Reference

Namespaces

 detail
 
 path_traits
 

Classes

class  basic_filebuf
 
class  basic_fstream
 
class  basic_ifstream
 
class  basic_ofstream
 
class  directory_entry
 
class  directory_iterator
 
class  file_status
 
class  filesystem_error
 
class  path
 
class  recursive_directory_iterator
 
struct  space_info
 

Typedefs

typedef basic_filebuf< char > filebuf
 
typedef basic_ifstream< char > ifstream
 
typedef basic_ofstream< char > ofstream
 
typedef basic_fstream< char > fstream
 
typedef basic_filebuf< wchar_t > wfilebuf
 
typedef basic_ifstream< wchar_t > wifstream
 
typedef basic_ofstream< wchar_t > wofstream
 
typedef basic_fstream< wchar_t > wfstream
 
typedef
recursive_directory_iterator 
wrecursive_directory_iterator
 
typedef path wpath
 

Enumerations

enum  file_type {
  status_error,
  status_unknown = status_error,
  file_not_found,
  regular_file,
  directory_file,
  symlink_file,
  block_file,
  character_file,
  fifo_file,
  socket_file,
  reparse_file,
  type_unknown,
  _detail_directory_symlink
}
 
enum  perms {
  no_perms = 0,
  owner_read = 0400,
  owner_write = 0200,
  owner_exe = 0100,
  owner_all = 0700,
  group_read = 040,
  group_write = 020,
  group_exe = 010,
  group_all = 070,
  others_read = 04,
  others_write = 02,
  others_exe = 01,
  others_all = 07,
  all_all = 0777,
  set_uid_on_exe = 04000,
  set_gid_on_exe = 02000,
  sticky_bit = 01000,
  perms_mask = 07777,
  perms_not_known = 0xFFFF,
  add_perms = 0x1000,
  remove_perms = 0x2000,
  symlink_perms = 0x4000
}
 

Functions

std::string extension (const path &p)
 
std::string basename (const path &p)
 
path change_extension (const path &p, const path &new_extension)
 
bool type_present (file_status f)
 
bool permissions_present (file_status f)
 
bool status_known (file_status f)
 
bool exists (file_status f)
 
bool is_regular_file (file_status f)
 
bool is_directory (file_status f)
 
bool is_symlink (file_status f)
 
bool is_other (file_status f)
 
bool is_regular (file_status f)
 
 BOOST_SCOPED_ENUM_START (copy_option)
 
file_status status (const path &p)
 
file_status status (const path &p, system::error_code &ec)
 
file_status symlink_status (const path &p)
 
file_status symlink_status (const path &p, system::error_code &ec)
 
bool exists (const path &p)
 
bool exists (const path &p, system::error_code &ec)
 
bool is_directory (const path &p)
 
bool is_directory (const path &p, system::error_code &ec)
 
bool is_regular_file (const path &p)
 
bool is_regular_file (const path &p, system::error_code &ec)
 
bool is_other (const path &p)
 
bool is_other (const path &p, system::error_code &ec)
 
bool is_symlink (const path &p)
 
bool is_symlink (const path &p, system::error_code &ec)
 
bool is_regular (const path &p)
 
bool is_regular (const path &p, system::error_code &ec)
 
bool is_empty (const path &p)
 
bool is_empty (const path &p, system::error_code &ec)
 
path current_path ()
 
path initial_path ()
 
BOOST_FILESYSTEM_DECL path absolute (const path &p, const path &base=current_path())
 
path canonical (const path &p, const path &base=current_path())
 
path canonical (const path &p, system::error_code &ec)
 
path canonical (const path &p, const path &base, system::error_code &ec)
 
path complete (const path &p)
 
path complete (const path &p, const path &base)
 
void copy (const path &from, const path &to)
 
void copy (const path &from, const path &to, system::error_code &ec)
 
void copy_directory (const path &from, const path &to)
 
void copy_directory (const path &from, const path &to, system::error_code &ec)
 
void copy_file (const path &from, const path &to, BOOST_SCOPED_ENUM(copy_option) option)
 
void copy_file (const path &from, const path &to)
 
void copy_file (const path &from, const path &to, BOOST_SCOPED_ENUM(copy_option) option, system::error_code &ec)
 
void copy_file (const path &from, const path &to, system::error_code &ec)
 
void copy_symlink (const path &existing_symlink, const path &new_symlink)
 
void copy_symlink (const path &existing_symlink, const path &new_symlink, system::error_code &ec)
 
bool create_directories (const path &p)
 
bool create_directories (const path &p, system::error_code &ec)
 
bool create_directory (const path &p)
 
bool create_directory (const path &p, system::error_code &ec)
 
void create_directory_symlink (const path &to, const path &from)
 
void create_directory_symlink (const path &to, const path &from, system::error_code &ec)
 
void create_hard_link (const path &to, const path &new_hard_link)
 
void create_hard_link (const path &to, const path &new_hard_link, system::error_code &ec)
 
void create_symlink (const path &to, const path &new_symlink)
 
void create_symlink (const path &to, const path &new_symlink, system::error_code &ec)
 
path current_path (system::error_code &ec)
 
void current_path (const path &p)
 
void current_path (const path &p, system::error_code &ec)
 
bool equivalent (const path &p1, const path &p2)
 
bool equivalent (const path &p1, const path &p2, system::error_code &ec)
 
boost::uintmax_t file_size (const path &p)
 
boost::uintmax_t file_size (const path &p, system::error_code &ec)
 
boost::uintmax_t hard_link_count (const path &p)
 
boost::uintmax_t hard_link_count (const path &p, system::error_code &ec)
 
path initial_path (system::error_code &ec)
 
std::time_t last_write_time (const path &p)
 
std::time_t last_write_time (const path &p, system::error_code &ec)
 
void last_write_time (const path &p, const std::time_t new_time)
 
void last_write_time (const path &p, const std::time_t new_time, system::error_code &ec)
 
void permissions (const path &p, perms prms)
 
void permissions (const path &p, perms prms, system::error_code &ec)
 
path read_symlink (const path &p)
 
path read_symlink (const path &p, system::error_code &ec)
 
bool remove (const path &p)
 
bool remove (const path &p, system::error_code &ec)
 
boost::uintmax_t remove_all (const path &p)
 
boost::uintmax_t remove_all (const path &p, system::error_code &ec)
 
void rename (const path &old_p, const path &new_p)
 
void rename (const path &old_p, const path &new_p, system::error_code &ec)
 
void resize_file (const path &p, uintmax_t size)
 
void resize_file (const path &p, uintmax_t size, system::error_code &ec)
 
space_info space (const path &p)
 
space_info space (const path &p, system::error_code &ec)
 
bool symbolic_link_exists (const path &p)
 
path system_complete (const path &p)
 
path system_complete (const path &p, system::error_code &ec)
 
path temp_directory_path ()
 
path temp_directory_path (system::error_code &ec)
 
path unique_path (const path &p="%%%%-%%%%-%%%%-%%%%")
 
path unique_path (const path &p, system::error_code &ec)
 
const directory_iteratorbegin (const directory_iterator &iter)
 
directory_iterator end (const directory_iterator &)
 
directory_iteratorrange_begin (directory_iterator &iter)
 
directory_iterator range_begin (const directory_iterator &iter)
 
directory_iterator range_end (const directory_iterator &)
 
 BOOST_SCOPED_ENUM_START (symlink_option)
 
const
recursive_directory_iterator
begin (const recursive_directory_iterator &iter)
 
recursive_directory_iterator end (const recursive_directory_iterator &)
 
recursive_directory_iteratorrange_begin (recursive_directory_iterator &iter)
 
recursive_directory_iterator range_begin (const recursive_directory_iterator &iter)
 
recursive_directory_iterator range_end (const recursive_directory_iterator &)
 
bool lexicographical_compare (path::iterator first1, path::iterator last1, path::iterator first2, path::iterator last2)
 
bool operator== (const path &lhs, const path &rhs)
 
bool operator== (const path &lhs, const path::string_type &rhs)
 
bool operator== (const path::string_type &lhs, const path &rhs)
 
bool operator== (const path &lhs, const path::value_type *rhs)
 
bool operator== (const path::value_type *lhs, const path &rhs)
 
bool operator!= (const path &lhs, const path &rhs)
 
bool operator!= (const path &lhs, const path::string_type &rhs)
 
bool operator!= (const path::string_type &lhs, const path &rhs)
 
bool operator!= (const path &lhs, const path::value_type *rhs)
 
bool operator!= (const path::value_type *lhs, const path &rhs)
 
bool operator< (const path &lhs, const path &rhs)
 
bool operator<= (const path &lhs, const path &rhs)
 
bool operator> (const path &lhs, const path &rhs)
 
bool operator>= (const path &lhs, const path &rhs)
 
std::size_t hash_value (const path &x)
 
void swap (path &lhs, path &rhs)
 
path operator/ (const path &lhs, const path &rhs)
 
template<class Char , class Traits >
std::basic_ostream< Char,
Traits > & 
operator<< (std::basic_ostream< Char, Traits > &os, const path &p)
 
template<class Char , class Traits >
std::basic_istream< Char,
Traits > & 
operator>> (std::basic_istream< Char, Traits > &is, path &p)
 
BOOST_FILESYSTEM_DECL bool portable_posix_name (const std::string &name)
 
BOOST_FILESYSTEM_DECL bool windows_name (const std::string &name)
 
BOOST_FILESYSTEM_DECL bool portable_name (const std::string &name)
 
BOOST_FILESYSTEM_DECL bool portable_directory_name (const std::string &name)
 
BOOST_FILESYSTEM_DECL bool portable_file_name (const std::string &name)
 
BOOST_FILESYSTEM_DECL bool native (const std::string &name)
 
template<>
std::string path::string< std::string > () const
 
template<>
std::wstring path::string< std::wstring > () const
 
template<>
std::string path::string< std::string > (const codecvt_type &cvt) const
 
template<>
std::wstring path::string< std::wstring > (const codecvt_type &cvt) const
 
template<>
std::string path::generic_string< std::string > () const
 
template<>
std::wstring path::generic_string< std::wstring > () const
 
template<>
std::string path::generic_string< std::string > (const codecvt_type &cvt) const
 
template<>
std::wstring path::generic_string< std::wstring > (const codecvt_type &cvt) const
 
BOOST_FILESYSTEM_DECL const
system::error_category
codecvt_error_category ()
 

Typedef Documentation

Enumeration Type Documentation

Enumerator
status_error 
status_unknown 
file_not_found 
regular_file 
directory_file 
symlink_file 
block_file 
character_file 
fifo_file 
socket_file 
reparse_file 
type_unknown 
_detail_directory_symlink 
Enumerator
no_perms 
owner_read 
owner_write 
owner_exe 
owner_all 
group_read 
group_write 
group_exe 
group_all 
others_read 
others_write 
others_exe 
others_all 
all_all 
set_uid_on_exe 
set_gid_on_exe 
sticky_bit 
perms_mask 
perms_not_known 
add_perms 
remove_perms 
symlink_perms 

Function Documentation

BOOST_FILESYSTEM_DECL path boost::filesystem::absolute ( const path &  p,
const path &  base = current_path() 
)

Referenced by complete().

std::string boost::filesystem::basename ( const path &  p)
inline
const directory_iterator& boost::filesystem::begin ( const directory_iterator &  iter)
inline
const recursive_directory_iterator& boost::filesystem::begin ( const recursive_directory_iterator &  iter)
inline
boost::filesystem::BOOST_SCOPED_ENUM_START ( copy_option  )
boost::filesystem::BOOST_SCOPED_ENUM_START ( symlink_option  )

References boost::none.

path boost::filesystem::canonical ( const path &  p,
const path &  base = current_path() 
)
inline
path boost::filesystem::canonical ( const path &  p,
system::error_code &  ec 
)
inline
path boost::filesystem::canonical ( const path &  p,
const path &  base,
system::error_code &  ec 
)
inline
path boost::filesystem::change_extension ( const path &  p,
const path &  new_extension 
)
inline
BOOST_FILESYSTEM_DECL const system::error_category& boost::filesystem::codecvt_error_category ( )
path boost::filesystem::complete ( const path &  p)
inline
path boost::filesystem::complete ( const path &  p,
const path &  base 
)
inline

References absolute().

void boost::filesystem::copy ( const path &  from,
const path &  to 
)
inline
void boost::filesystem::copy ( const path &  from,
const path &  to,
system::error_code &  ec 
)
inline
void boost::filesystem::copy_directory ( const path &  from,
const path &  to 
)
inline
void boost::filesystem::copy_directory ( const path &  from,
const path &  to,
system::error_code &  ec 
)
inline
void boost::filesystem::copy_file ( const path &  from,
const path &  to,
BOOST_SCOPED_ENUM(copy_option)  option 
)
inline
void boost::filesystem::copy_file ( const path &  from,
const path &  to 
)
inline
void boost::filesystem::copy_file ( const path &  from,
const path &  to,
BOOST_SCOPED_ENUM(copy_option)  option,
system::error_code &  ec 
)
inline
void boost::filesystem::copy_file ( const path &  from,
const path &  to,
system::error_code &  ec 
)
inline
void boost::filesystem::copy_symlink ( const path &  existing_symlink,
const path &  new_symlink 
)
inline
void boost::filesystem::copy_symlink ( const path &  existing_symlink,
const path &  new_symlink,
system::error_code &  ec 
)
inline
bool boost::filesystem::create_directories ( const path &  p)
inline
bool boost::filesystem::create_directories ( const path &  p,
system::error_code &  ec 
)
inline
bool boost::filesystem::create_directory ( const path &  p)
inline
bool boost::filesystem::create_directory ( const path &  p,
system::error_code &  ec 
)
inline
void boost::filesystem::create_directory_symlink ( const path &  to,
const path &  from 
)
inline
void boost::filesystem::create_directory_symlink ( const path &  to,
const path &  from,
system::error_code &  ec 
)
inline
void boost::filesystem::create_hard_link ( const path &  to,
const path &  new_hard_link 
)
inline
void boost::filesystem::create_hard_link ( const path &  to,
const path &  new_hard_link,
system::error_code &  ec 
)
inline
void boost::filesystem::create_symlink ( const path &  to,
const path &  new_symlink 
)
inline
void boost::filesystem::create_symlink ( const path &  to,
const path &  new_symlink,
system::error_code &  ec 
)
inline
path boost::filesystem::current_path ( )
inline
path boost::filesystem::current_path ( system::error_code &  ec)
inline
void boost::filesystem::current_path ( const path &  p)
inline
void boost::filesystem::current_path ( const path &  p,
system::error_code &  ec 
)
inline
directory_iterator boost::filesystem::end ( const directory_iterator &  )
inline
recursive_directory_iterator boost::filesystem::end ( const recursive_directory_iterator &  )
inline
bool boost::filesystem::equivalent ( const path &  p1,
const path &  p2 
)
inline
bool boost::filesystem::equivalent ( const path &  p1,
const path &  p2,
system::error_code &  ec 
)
inline
bool boost::filesystem::exists ( const path &  p)
inline
bool boost::filesystem::exists ( const path &  p,
system::error_code &  ec 
)
inline
std::string boost::filesystem::extension ( const path &  p)
inline
boost::uintmax_t boost::filesystem::file_size ( const path &  p)
inline
boost::uintmax_t boost::filesystem::file_size ( const path &  p,
system::error_code &  ec 
)
inline
boost::uintmax_t boost::filesystem::hard_link_count ( const path &  p)
inline
boost::uintmax_t boost::filesystem::hard_link_count ( const path &  p,
system::error_code &  ec 
)
inline
path boost::filesystem::initial_path ( )
inline
path boost::filesystem::initial_path ( system::error_code &  ec)
inline
bool boost::filesystem::is_directory ( const path &  p)
inline
bool boost::filesystem::is_directory ( const path &  p,
system::error_code &  ec 
)
inline
bool boost::filesystem::is_empty ( const path &  p)
inline
bool boost::filesystem::is_empty ( const path &  p,
system::error_code &  ec 
)
inline
bool boost::filesystem::is_other ( file_status  f)
inline
bool boost::filesystem::is_other ( const path &  p)
inline
bool boost::filesystem::is_other ( const path &  p,
system::error_code &  ec 
)
inline
bool boost::filesystem::is_regular ( file_status  f)
inline
bool boost::filesystem::is_regular ( const path &  p)
inline
bool boost::filesystem::is_regular ( const path &  p,
system::error_code &  ec 
)
inline
bool boost::filesystem::is_regular_file ( file_status  f)
inline
bool boost::filesystem::is_regular_file ( const path &  p)
inline
bool boost::filesystem::is_regular_file ( const path &  p,
system::error_code &  ec 
)
inline
bool boost::filesystem::is_symlink ( file_status  f)
inline
bool boost::filesystem::is_symlink ( const path &  p)
inline
bool boost::filesystem::is_symlink ( const path &  p,
system::error_code &  ec 
)
inline
std::time_t boost::filesystem::last_write_time ( const path &  p)
inline
std::time_t boost::filesystem::last_write_time ( const path &  p,
system::error_code &  ec 
)
inline
void boost::filesystem::last_write_time ( const path &  p,
const std::time_t  new_time 
)
inline
void boost::filesystem::last_write_time ( const path &  p,
const std::time_t  new_time,
system::error_code &  ec 
)
inline
bool boost::filesystem::lexicographical_compare ( path::iterator  first1,
path::iterator  last1,
path::iterator  first2,
path::iterator  last2 
)
inline
BOOST_FILESYSTEM_DECL bool boost::filesystem::native ( const std::string &  name)
bool boost::filesystem::operator!= ( const path &  lhs,
const path &  rhs 
)
inline
bool boost::filesystem::operator!= ( const path &  lhs,
const path::string_type &  rhs 
)
inline
bool boost::filesystem::operator!= ( const path::string_type &  lhs,
const path &  rhs 
)
inline
bool boost::filesystem::operator!= ( const path &  lhs,
const path::value_type *  rhs 
)
inline
bool boost::filesystem::operator!= ( const path::value_type *  lhs,
const path &  rhs 
)
inline
path boost::filesystem::operator/ ( const path &  lhs,
const path &  rhs 
)
inline
bool boost::filesystem::operator< ( const path &  lhs,
const path &  rhs 
)
inline
template<class Char , class Traits >
std::basic_ostream<Char, Traits>& boost::filesystem::operator<< ( std::basic_ostream< Char, Traits > &  os,
const path &  p 
)
inline
bool boost::filesystem::operator<= ( const path &  lhs,
const path &  rhs 
)
inline
bool boost::filesystem::operator== ( const path &  lhs,
const path &  rhs 
)
inline
bool boost::filesystem::operator== ( const path &  lhs,
const path::string_type &  rhs 
)
inline
bool boost::filesystem::operator== ( const path::string_type &  lhs,
const path &  rhs 
)
inline
bool boost::filesystem::operator== ( const path &  lhs,
const path::value_type *  rhs 
)
inline
bool boost::filesystem::operator== ( const path::value_type *  lhs,
const path &  rhs 
)
inline
bool boost::filesystem::operator> ( const path &  lhs,
const path &  rhs 
)
inline
bool boost::filesystem::operator>= ( const path &  lhs,
const path &  rhs 
)
inline
template<class Char , class Traits >
std::basic_istream<Char, Traits>& boost::filesystem::operator>> ( std::basic_istream< Char, Traits > &  is,
path &  p 
)
inline

References boost::str().

template<>
std::string boost::filesystem::path::generic_string< std::string > ( ) const
inline
template<>
std::string boost::filesystem::path::generic_string< std::string > ( const codecvt_type &  cvt) const
inline
template<>
std::wstring boost::filesystem::path::generic_string< std::wstring > ( ) const
inline
template<>
std::wstring boost::filesystem::path::generic_string< std::wstring > ( const codecvt_type &  cvt) const
inline
template<>
std::string boost::filesystem::path::string< std::string > ( ) const
inline
template<>
std::string boost::filesystem::path::string< std::string > ( const codecvt_type &  cvt) const
inline
template<>
std::wstring boost::filesystem::path::string< std::wstring > ( ) const
inline
template<>
std::wstring boost::filesystem::path::string< std::wstring > ( const codecvt_type &  cvt) const
inline
void boost::filesystem::permissions ( const path &  p,
perms  prms 
)
inline
void boost::filesystem::permissions ( const path &  p,
perms  prms,
system::error_code &  ec 
)
inline
bool boost::filesystem::permissions_present ( file_status  f)
inline
BOOST_FILESYSTEM_DECL bool boost::filesystem::portable_directory_name ( const std::string &  name)
BOOST_FILESYSTEM_DECL bool boost::filesystem::portable_file_name ( const std::string &  name)
BOOST_FILESYSTEM_DECL bool boost::filesystem::portable_name ( const std::string &  name)
BOOST_FILESYSTEM_DECL bool boost::filesystem::portable_posix_name ( const std::string &  name)
directory_iterator& boost::filesystem::range_begin ( directory_iterator &  iter)
inline
directory_iterator boost::filesystem::range_begin ( const directory_iterator &  iter)
inline
recursive_directory_iterator& boost::filesystem::range_begin ( recursive_directory_iterator &  iter)
inline
recursive_directory_iterator boost::filesystem::range_begin ( const recursive_directory_iterator &  iter)
inline
directory_iterator boost::filesystem::range_end ( const directory_iterator &  )
inline
recursive_directory_iterator boost::filesystem::range_end ( const recursive_directory_iterator &  )
inline
path boost::filesystem::read_symlink ( const path &  p)
inline
path boost::filesystem::read_symlink ( const path &  p,
system::error_code &  ec 
)
inline
bool boost::filesystem::remove ( const path &  p)
inline
bool boost::filesystem::remove ( const path &  p,
system::error_code &  ec 
)
inline
boost::uintmax_t boost::filesystem::remove_all ( const path &  p)
inline
boost::uintmax_t boost::filesystem::remove_all ( const path &  p,
system::error_code &  ec 
)
inline
void boost::filesystem::rename ( const path &  old_p,
const path &  new_p 
)
inline
void boost::filesystem::rename ( const path &  old_p,
const path &  new_p,
system::error_code &  ec 
)
inline
void boost::filesystem::resize_file ( const path &  p,
uintmax_t  size 
)
inline
void boost::filesystem::resize_file ( const path &  p,
uintmax_t  size,
system::error_code &  ec 
)
inline
space_info boost::filesystem::space ( const path &  p)
inline
space_info boost::filesystem::space ( const path &  p,
system::error_code &  ec 
)
inline
file_status boost::filesystem::status ( const path &  p)
inline
file_status boost::filesystem::status ( const path &  p,
system::error_code &  ec 
)
inline
bool boost::filesystem::status_known ( file_status  f)
inline
void boost::filesystem::swap ( path &  lhs,
path &  rhs 
)
inline
bool boost::filesystem::symbolic_link_exists ( const path &  p)
inline

References is_symlink(), and symlink_status().

file_status boost::filesystem::symlink_status ( const path &  p)
inline
file_status boost::filesystem::symlink_status ( const path &  p,
system::error_code &  ec 
)
inline
path boost::filesystem::system_complete ( const path &  p)
inline
path boost::filesystem::system_complete ( const path &  p,
system::error_code &  ec 
)
inline
path boost::filesystem::temp_directory_path ( )
inline
path boost::filesystem::temp_directory_path ( system::error_code &  ec)
inline
bool boost::filesystem::type_present ( file_status  f)
inline
path boost::filesystem::unique_path ( const path &  p = "%%%%-%%%%-%%%%-%%%%")
inline
path boost::filesystem::unique_path ( const path &  p,
system::error_code &  ec 
)
inline
BOOST_FILESYSTEM_DECL bool boost::filesystem::windows_name ( const std::string &  name)