Class DirectoryHelper
A helper class for Directory operations.
Inheritance
System.Object
DirectoryHelper
Assembly: Volo.Abp.Core.dll
Syntax
public static class DirectoryHelper : object
Methods
ChangeCurrentDirectory(String)
Declaration
public static IDisposable ChangeCurrentDirectory(string targetDirectory)
Parameters
| Type |
Name |
Description |
| System.String |
targetDirectory |
|
Returns
| Type |
Description |
| IDisposable |
|
CreateIfNotExists(DirectoryInfo)
Declaration
public static void CreateIfNotExists(DirectoryInfo directory)
Parameters
| Type |
Name |
Description |
| DirectoryInfo |
directory |
|
CreateIfNotExists(String)
Declaration
public static void CreateIfNotExists(string directory)
Parameters
| Type |
Name |
Description |
| System.String |
directory |
|
DeleteIfExists(String)
Declaration
public static void DeleteIfExists(string directory)
Parameters
| Type |
Name |
Description |
| System.String |
directory |
|
DeleteIfExists(String, Boolean)
Declaration
public static void DeleteIfExists(string directory, bool recursive)
Parameters
| Type |
Name |
Description |
| System.String |
directory |
|
| System.Boolean |
recursive |
|
IsSubDirectoryOf(DirectoryInfo, DirectoryInfo)
Declaration
public static bool IsSubDirectoryOf(DirectoryInfo parentDirectory, DirectoryInfo childDirectory)
Parameters
| Type |
Name |
Description |
| DirectoryInfo |
parentDirectory |
|
| DirectoryInfo |
childDirectory |
|
Returns
| Type |
Description |
| System.Boolean |
|
IsSubDirectoryOf(String, String)
Declaration
public static bool IsSubDirectoryOf(string parentDirectoryPath, string childDirectoryPath)
Parameters
| Type |
Name |
Description |
| System.String |
parentDirectoryPath |
|
| System.String |
childDirectoryPath |
|
Returns
| Type |
Description |
| System.Boolean |
|