MAKE_OPERATOR_EQ
MAKE_OPERATOR_REL
MAKE_OPERATOR
UNISTDX_FS_PATH
using path = basic_path< char >

Specialisation of basic_path for char.

template <class Ch, class Tr = std::char_traits<Ch>, class Alloc = std::allocator<Ch>>
class sys::basic_path

File system path template which is a std::string with additional methods.

Ch
character type

Tr
character traits type

Alloc
allocator type

Types
  • using string_type = std::basic_string< Ch, Tr, Alloc >

    String type.

Methods
  • attributes(file_attribute_options f = file_attribute_options{}) const -> file_attributes
  • remove_attribute(c_string name, file_attribute_options f = file_attribute_options{}) -> void
  • attribute(c_string name, const_string value, file_attribute_flags f1 = file_attribute_flags{}, file_attribute_options f = file_attribute_options{}) -> void
  • attribute(c_string name, file_attribute_options f = file_attribute_options{}) const -> string
  • swap(basic_path & rhs) -> void

    Swap with rhs.

  • operator const value_type *() const

    Automatically cast to const char* which is oftet used in system calls.

  • template <class T, class ... Args>
    add(T && filename, Args &&... components) -> void

    Append method arguments as path components.

  • template <class T>
    add(T && filename) -> void

    Append file filename as path component.

  • template <class A, class B, class ... Args>
    basic_path(A && dir, B && filename, Args &&... more_filenames)

    Construct path from multiple path components.

  • template <class A, class B>
    basic_path(A && dir, B && filename)

    Construct path from directory dir and file filename.

  • basic_path(basic_path && rhs)

    Move-constructor.

  • basic_path(const basic_path & rhs)

    Copy-constructor.

  • basic_path(string_type && rhs)explicit

    Move-constructor for string.

  • basic_path(const string_type & rhs)explicit

    Copy-constructor for string.

  • basic_path(const char * rhs)explicit

    Construct path from bar const char*.

  • operator=(const char * rhs) -> basic_path &

    Assignment.

  • operator=(string_type && rhs) -> basic_path &

    Move-assignment for string.

  • operator=(const string_type & rhs) -> basic_path &

    Copy-assignment for string.

  • operator=(basic_path &&) -> basic_path &

    Move-assignment.

  • operator=(const basic_path &) -> basic_path &

    Copy-assignment.

  • basic_path()
Friends
  • basic_canonical_path< Ch, Tr, Alloc >
  • std::hash< basic_path >
  • operator>=
  • operator>
  • operator<=
  • operator<
  • operator>=
  • operator>
  • operator<=
  • operator<
  • operator>=
  • operator>
  • operator<=
  • operator<
  • operator>=
  • operator>
  • operator<=
  • operator<
  • operator>=
  • operator>
  • operator<=
  • operator<
  • operator!=
  • operator==
  • operator!=
  • operator==
  • operator!=
  • operator==
  • operator!=
  • operator==
  • operator!=
  • operator==
template <class Ch, class Tr, class Alloc>
struct std::hash< sys::basic_path< Ch, Tr, Alloc > >

Specialisation of std::hash for sys::basic_path.

Base classes
  • public std::hash< std::basic_string< Ch, Tr, Alloc > >
Types
  • using argument_type = sys::basic_path< Ch, Tr, Alloc >

    Hash function argument type.

  • using result_type = size_t

    Hash function return value type.

Methods
template <class Ch, class Tr, class Alloc>
swap(basic_path< Ch, Tr, Alloc > & lhs, basic_path< Ch, Tr, Alloc > & rhs) -> void

Overload of std::swap for basic_path.

constexpr const char path_separator

Path separator in environment variables.

constexpr const char file_separator

Path components separator.