47 lines
1.0 KiB
C#
47 lines
1.0 KiB
C#
using System;
|
|
using System.Collections.Generic;
|
|
using System.Linq;
|
|
using System.Text;
|
|
using System.Threading.Tasks;
|
|
|
|
namespace HardDiskPartition
|
|
{
|
|
public class hardiskPartition
|
|
{
|
|
private string _PartitionName;
|
|
private double _FreeSpace;
|
|
private double _SumSpace;
|
|
///
|
|
/// 空余大小
|
|
///
|
|
public double FreeSpace
|
|
{
|
|
get { return _FreeSpace; }
|
|
set { this._FreeSpace = value; }
|
|
}
|
|
///
|
|
/// 使用空间
|
|
///
|
|
public double UseSpace
|
|
{
|
|
get { return _SumSpace - _FreeSpace; }
|
|
}
|
|
///
|
|
/// 总空间
|
|
///
|
|
public double SumSpace
|
|
{
|
|
get { return _SumSpace; }
|
|
set { this._SumSpace = value; }
|
|
}
|
|
///
|
|
/// 分区名称
|
|
///
|
|
public string PartitionName
|
|
{
|
|
get { return _PartitionName; }
|
|
set { this._PartitionName = value; }
|
|
}
|
|
}
|
|
}
|