FileSystem
File system utilities.
Initializers
using AlibabaCloud.SDK.ROS.CDK.Core;
new FileSystem();
Name | Type | Description |
---|---|---|
Static Functions
Name | Description |
---|---|
CopyDirectory |
Copies an entire directory structure. |
Fingerprint |
Produces fingerprint based on the contents of a single file or an entire directory tree. |
IsEmpty |
Checks whether a directory is empty. |
Mkdtemp |
Creates a unique temporary directory in the system temp directory. |
CopyDirectory
using AlibabaCloud.SDK.ROS.CDK.Core;
FileSystem.CopyDirectory(string SrcDir, string DestDir, CopyOptions Options = null, string RootDir = null);
Copies an entire directory structure.
- Type: string
Source directory.
- Type: string
Destination directory.
- Type: CopyOptions
options.
- Type: string
Root directory to calculate exclusions from.
Fingerprint
using AlibabaCloud.SDK.ROS.CDK.Core;
FileSystem.Fingerprint(string FileOrDirectory, FingerprintOptions Options = null);
Produces fingerprint based on the contents of a single file or an entire directory tree.
Line endings are converted from CRLF to LF.
The fingerprint will also include:
- An extra string if defined in
options.extra
. - The symlink follow mode value.
- Type: string
The directory or file to fingerprint.
- Type: FingerprintOptions
Fingerprinting options.
IsEmpty
using AlibabaCloud.SDK.ROS.CDK.Core;
FileSystem.IsEmpty(string Dir);
Checks whether a directory is empty.
- Type: string
The directory to check.
Mkdtemp
using AlibabaCloud.SDK.ROS.CDK.Core;
FileSystem.Mkdtemp(string Prefix);
Creates a unique temporary directory in the system temp directory.
- Type: string
A prefix for the directory name.
Six random characters will be generated and appended behind this prefix.
Properties
Name | Type | Description |
---|---|---|
Tmpdir |
string |
The real path of the system temp directory. |
Tmpdir
Required
public string Tmpdir { get; }
- Type: string
The real path of the system temp directory.