4 using System.ComponentModel;
6 namespace SiliconStudio.Core.IO
11 [DataContract(
"UDirectory")]
29 public UDirectory(
string directoryPath) : base(directoryPath, true)
44 return (
UDirectory)base.MakeRelative(anchorDirectory);
52 public static implicit
operator UDirectory(
string fullPath)
54 return fullPath != null ?
new UDirectory(fullPath) : null;
64 if (path == null)
throw new ArgumentNullException(
"path");
65 if (FullPath == null)
return false;
66 if (path.
FullPath == null)
return false;
68 return path.FullPath.StartsWith(FullPath, StringComparison.OrdinalIgnoreCase) && path.
FullPath.Length > FullPath.Length && path.
FullPath[FullPath.Length] == DirectorySeparatorChar;
new UDirectory MakeRelative(UDirectory anchorDirectory)
Makes this instance relative to the specified anchor directory.
string FullPath
Gets the full path ((drive?)(directory?/)(name.ext?)). An empty path is an empty string.
UDirectory(string directoryPath)
Initializes a new instance of the UDirectory class.
Defines a normalized directory path. See UPath for details. This class cannot be inherited.
Base class that describes a uniform path and provides method to manipulate them. Concrete class are U...
delegate object TypeConverter(object arg)
bool Contains(UPath path)
Determines whether this directory contains the specified path.
A region of character in a string.