RLib  5.7
RLib - an opensource, lightweight and multi-platform framework for cpp programming
System::IO::Path Struct Reference

Represents filesystem path More...

Public Member Functions

 Path (const String &)
 
 operator const String & () const
 Gets the absolute NT path More...
 
 operator const PathInfo & () const
 Gets the path info More...
 
String GetDosPath ()
 Gets the absolute MS-DOS path More...
 
 RLIB_PROPERTY_GET (String DosPath, GetDosPath)
 Gets the absolute MS-DOS path More...
 
String GetDirectory ()
 Gets the directory, eg. C:\ More...
 
 RLIB_PROPERTY_GET (String Directory, GetDirectory)
 Gets the directory, eg. C:\ More...
 
String GetFileName ()
 Gets the file name, eg. RLib.dll More...
 
 RLIB_PROPERTY_GET (String FileName, GetFileName)
 Gets the file name, eg. RLib.dll More...
 
bool IsRoot ()
 Determines if this path is a root path More...
 

Static Public Member Functions

static String ToBackslash (const String &path)
 Converts forward slash to backslash in path More...
 
static String ToForwardslash (const String &path)
 Converts forward slash to backslash in path More...
 
static String ToNtPath (const String &path)
 Converts path to absolute NT path More...
 
static String ToDosPath (const String &path, bool nt_processed=false)
 Converts path to absolute MS-DOS path More...
 
static String AddBackslash (const String &path)
 Append a backslash _T('\') to a path if one doesn't exist More...
 
static String RemoveBackslash (const String &path)
 Remove a trailing backslash from a path More...
 
static String QuoteSpaces (const String &path)
 Surround a path containing spaces in quotes. The path is not changed if it has no spaces More...
 
static bool IsRoot (const String &path)
 Determines if a path is a root path. If path is relative path, this method returns false immediately More...
 
static bool IsRelative (const String &path)
 Determines if a path is a relative path More...
 
static String RelativePathTo (const String &path_from, const String &path_to)
 Creates a relative path from one path to another. If the paths do not share a common prefix, this method returns absolute path of path_to More...
 

Public Attributes

 RLIB_DECLARE_DYNCREATE
 

Protected Attributes

PathInfo m_PathInfo
 
String m_FullPath
 

Detailed Description

Represents filesystem path

Member Function Documentation

String Path::AddBackslash ( const String path)
static

Append a backslash _T('\') to a path if one doesn't exist

String Path::GetDirectory ( )

Gets the directory, eg. C:\

String Path::GetDosPath ( )

Gets the absolute MS-DOS path

String Path::GetFileName ( )

Gets the file name, eg. RLib.dll

bool Path::IsRelative ( const String path)
static

Determines if a path is a relative path

bool Path::IsRoot ( )

Determines if this path is a root path

bool Path::IsRoot ( const String path)
static

Determines if a path is a root path. If path is relative path, this method returns false immediately

System::IO::Path::operator const PathInfo & ( ) const
inline

Gets the path info

System::IO::Path::operator const String & ( ) const
inline

Gets the absolute NT path

String Path::QuoteSpaces ( const String path)
static

Surround a path containing spaces in quotes. The path is not changed if it has no spaces

String Path::RelativePathTo ( const String path_from,
const String path_to 
)
static

Creates a relative path from one path to another. If the paths do not share a common prefix, this method returns absolute path of path_to

String Path::RemoveBackslash ( const String path)
static

Remove a trailing backslash from a path

System::IO::Path::RLIB_PROPERTY_GET ( String  DosPath,
GetDosPath   
)

Gets the absolute MS-DOS path

System::IO::Path::RLIB_PROPERTY_GET ( String  Directory,
GetDirectory   
)

Gets the directory, eg. C:\

System::IO::Path::RLIB_PROPERTY_GET ( String  FileName,
GetFileName   
)

Gets the file name, eg. RLib.dll

String Path::ToBackslash ( const String path)
static

Converts forward slash to backslash in path

String Path::ToDosPath ( const String path,
bool  nt_processed = false 
)
static

Converts path to absolute MS-DOS path

String Path::ToForwardslash ( const String path)
static

Converts forward slash to backslash in path

String Path::ToNtPath ( const String path)
static

Converts path to absolute NT path


The documentation for this struct was generated from the following files: