Class DiskInfoNativeMethods
Inheritance
System.Object
DiskInfoNativeMethods
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: CrashCABN.Shared
Assembly: CrashCABN.Shared.DiskInfo.dll
Syntax
public static class DiskInfoNativeMethods
Methods
View SourceGetDiskFreeSpace(String)
Retrieve information about the disk space for a given path. UNC is supported (with a trailing slash).
Declaration
public static (ulong FreeBytes, ulong TotalBytes, ulong DiskFreeBytes) GetDiskFreeSpace(string path)
Parameters
Type | Name | Description |
---|---|---|
System.String | path | The folder path to evaluate. Passing null will return the value of the current drive. |
Returns
Type | Description |
---|---|
System.ValueTuple<System.UInt64, System.UInt64, System.UInt64> | A tuple containing: the total number of free bytes on a disk for the current user, the total number of bytes on a disk for the current user, and the total number of free bytes on a disk. |