C# Class BetterExplorer.FriendlySizeConverter

Contains functionality for presenting the size of a file
显示文件 Open project: Gainedge/BetterExplorer Class Usage Examples

Public Methods

Method Description
GetByteLength ( double size, FileSizeMeasurements type ) : long

Converts a the size of a file in units (FileSizeMeasurements and double) into the number of bytes

GetFriendlySize ( double bytes ) : string

Converts bytes into a user friendly string converted into larger units when desired.

Method Details

GetByteLength() public static method

Converts a the size of a file in units (FileSizeMeasurements and double) into the number of bytes
public static GetByteLength ( double size, FileSizeMeasurements type ) : long
size double
type FileSizeMeasurements
return long

GetFriendlySize() public static method

Converts bytes into a user friendly string converted into larger units when desired.
public static GetFriendlySize ( double bytes ) : string
bytes double The number of bytes
return string