ShellBrowser Delphi Components Documentation
ContentsIndexHome
PreviousUpNext
Jam.Shell.PathUtils.TPathUtils.IsRooted

Returns true if the given path is rooted. This is required since "directory" is considered absolute to the current drive but the target may vary when the current drive is changed.

Syntax
Pascal
class function IsRooted(const pPath: String): Boolean; static;
Parameters 
Description 
const pPath: String 
The path to test. 

Boolean: True, if the path is explitly rooted to a drive or UNC. False is all other cases.

This function can also handle URLs and retrunes True if the given path is an URL.  

In opposite to System.IOUtils.TPath.IsPathRooted() this function also considers a path like "directory" as not rooted. But since such a path is relative to the current drive we need to handle it as not rooted. Changing this behavior would have as result unexpected behavior in some other functions (e.g. TPath.MakeCanonic() and TPath.RemoveDriveIndicatorChar).

roth