Boost.AFIO    Boost C++ Libraries
Classes | Public Types | Public Member Functions | Friends
boost::afio::path Class Reference

An AFIO filesystem path, a thin wrapper of filesystem::path used to mark when a filesystem path has been prepared for AFIO usage. Note that on Windows this exclusively refers to a case sensitive NT kernel path, not a Win32 path (Win32 paths are converted in the constructor). More...

Inheritance diagram for boost::afio::path:
boost::afio::path::make_absolute

List of all members.

Classes

struct  direct
struct  make_absolute
 Makes a path absolute according to the current working directory. More...

Public Types

typedef
filesystem::path::value_type 
value_type
typedef
filesystem::path::string_type 
string_type
typedef filesystem::path::iterator iterator
typedef
filesystem::path::const_iterator 
const_iterator

Public Member Functions

 path ()
 Default constructor.
 path (const path &p)
 Copy constructor.
 path (const filesystem::path &p)
 Converts a filesystem::path to AFIO format.
 path (const char *p)
 Converts a filesystem::path to AFIO format.
 path (const string_type &p)
 Converts a filesystem::path to AFIO format.
 path (path &&p) noexcept
 Move constructor.
 path (filesystem::path &&p)
 Converts a filesystem::path to AFIO format.
 path (string_type &&p)
 Converts a filesystem::path to AFIO format.
template<class InputIterator >
 path (InputIterator begin, InputIterator end)
 Converts source to AFIO path format.
pathoperator= (const path &p)
 Copy assignment.
pathoperator= (path &&p) noexcept
 Move assignment.
template<class Source >
pathassign (Source const &source)
 Converts source to AFIO path format.
template<class InputIterator >
pathassign (InputIterator begin, InputIterator end)
pathoperator/= (const path &p)
template<class Source >
pathoperator/= (Source const &source)
template<class Source >
pathappend (Source const &source)
template<class InputIterator >
pathappend (InputIterator begin, InputIterator end)
pathoperator+= (const path &x)
pathoperator+= (const string_type &x)
pathoperator+= (const value_type *x)
pathoperator+= (value_type x)
template<class Source >
pathoperator+= (Source const &x)
template<class Source >
pathconcat (Source const &x)
template<class InputIterator >
pathconcat (InputIterator begin, InputIterator end)
pathmake_preferred ()
pathremove_filename ()
pathreplace_extension (const path &new_extension=path())
path root_name () const
path root_directory () const
path root_path () const
path relative_path () const
path parent_path () const
path filename () const
path stem () const
path extension () const
iterator begin () const
iterator end () const
filesystem::path filesystem_path () const
 Return a normalised filesystem::path from an AFIO path.

Friends

struct detail::async_io_handle_windows
struct path_hash
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)
bool operator== (const path &lhs, const path &rhs)
bool operator!= (const path &lhs, const path &rhs)
path operator/ (const path &lhs, const path &rhs)
std::ostream & operator<< (std::ostream &s, const path &p)
filesystem::path normalise_path (path p, path_normalise type)
 Return a normalised filesystem::path from an AFIO path.

Detailed Description

An AFIO filesystem path, a thin wrapper of filesystem::path used to mark when a filesystem path has been prepared for AFIO usage. Note that on Windows this exclusively refers to a case sensitive NT kernel path, not a Win32 path (Win32 paths are converted in the constructor).

Definition at line 397 of file afio.hpp.


Constructor & Destructor Documentation

boost::afio::path::path ( )

Default constructor.

Definition at line 453 of file afio.hpp.

boost::afio::path::path ( const path p)

Copy constructor.

Definition at line 455 of file afio.hpp.

boost::afio::path::path ( const filesystem::path &  p)

Converts a filesystem::path to AFIO format.

Definition at line 457 of file afio.hpp.

boost::afio::path::path ( const char *  p)

Converts a filesystem::path to AFIO format.

Definition at line 459 of file afio.hpp.

boost::afio::path::path ( const string_type &  p)

Converts a filesystem::path to AFIO format.

Definition at line 467 of file afio.hpp.

boost::afio::path::path ( path &&  p)

Move constructor.

Definition at line 469 of file afio.hpp.

boost::afio::path::path ( filesystem::path &&  p)

Converts a filesystem::path to AFIO format.

Definition at line 471 of file afio.hpp.

boost::afio::path::path ( string_type &&  p)

Converts a filesystem::path to AFIO format.

Definition at line 477 of file afio.hpp.

template<class InputIterator >
boost::afio::path::path ( InputIterator  begin,
InputIterator  end 
)

Converts source to AFIO path format.

Converts source to AFIO path format

Definition at line 481 of file afio.hpp.


Member Function Documentation

path& boost::afio::path::operator= ( const path p)

Copy assignment.

Definition at line 483 of file afio.hpp.

path& boost::afio::path::operator= ( path &&  p)

Move assignment.

Definition at line 485 of file afio.hpp.

template<class Source >
path& boost::afio::path::assign ( Source const &  source)

Converts source to AFIO path format.

Definition at line 490 of file afio.hpp.

filesystem::path boost::afio::path::filesystem_path ( ) const

Return a normalised filesystem::path from an AFIO path.

On POSIX this passes through its input unchanged.

On Windows AFIO exclusively uses NT kernel paths which are not necessarily trivially convertible to Win32 paths. As an example, the Win32 path `C:` might be `\??:` or even ``. This function will convert any NT kernel path into something which can be fed to normal Win32 APIs quickly, though note that the output path will be rejected by most other APIs as invalid. If you need a Win32 path which is completely valid, use normalise_path().

Definition at line 568 of file afio.hpp.


Friends And Related Function Documentation

filesystem::path normalise_path ( path  p,
path_normalise  type = path_normalise::dos 
) [friend]

Return a normalised filesystem::path from an AFIO path.

On POSIX this passes through its input unchanged.

On Windows AFIO exclusively uses NT kernel paths which are not necessarily trivially convertible to Win32 paths. As an example, the Win32 path `C:\Foo` might be `\??\C:\Foo` or even `\Device\HarddiskVolume1\Foo`. This function will convert any NT kernel path into something which can be fed to normal Win32 APIs - a drive letter if available, else a GUID volume path, and with an extended path prefix if the path is sufficiently long. It also scans the path for characters illegal under Win32 or paths which begin with a space or end with a period, and will extended path prefix such paths as well.

Parameters:
pPath to be normalised
typeA path_normalise enum

Definition at line 657 of file afio.hpp.


January, 2014

Copyright © 2013-2014 Niall Douglas, Cork, Ireland
Copyright © 2013 Paul Kirth, California
Documentation is generated by Doxygen