C# Class Evbpc.Framework.Utilities.DataSize

Mostrar archivo Open project: EBrown8534/Framework Class Usage Examples

Public Methods

Method Description
DataSize ( ulong sizeInBytes ) : System
DataSize ( ulong sizeInBytes, SizeUnit unit ) : System
Equals ( object obj ) : bool
From ( double size, SizeUnit unit ) : DataSize
GetHashCode ( ) : int
GetLargestWholeSize ( SizeUnit unit = null ) : DataSize

Returns a DataSize that is the highest value which will have a non-zero whole-number Size component.

GetSize ( SizeUnit unit ) : double
GetSmallestPartialSize ( SizeUnit unit = null ) : DataSize

Returns a DataSize that is the smallest value which will have a zero whole-number Size component.

IsSame ( DataSize comparison ) : bool
IsSame ( DataSize left, DataSize right ) : bool
ToString ( ) : string
ToString ( SizeUnit unit ) : string
ToString ( string numberFormat ) : string
ToString ( string numberFormat, SizeUnit unit ) : string
operator ( ) : DataSize
operator ( ) : bool

Private Methods

Method Description
DataSize ( double size, SizeUnit unit ) : System

Method Details

DataSize() public method

public DataSize ( ulong sizeInBytes ) : System
sizeInBytes ulong
return System

DataSize() public method

public DataSize ( ulong sizeInBytes, SizeUnit unit ) : System
sizeInBytes ulong
unit SizeUnit
return System

Equals() public method

public Equals ( object obj ) : bool
obj object
return bool

From() public static method

public static From ( double size, SizeUnit unit ) : DataSize
size double
unit SizeUnit
return DataSize

GetHashCode() public method

public GetHashCode ( ) : int
return int

GetLargestWholeSize() public method

Returns a DataSize that is the highest value which will have a non-zero whole-number Size component.
public GetLargestWholeSize ( SizeUnit unit = null ) : DataSize
unit SizeUnit When set to the result will be a B type, when set to the result will be a iB type. If set to null the same base unit as the source value will be used.
return DataSize

GetSize() public method

public GetSize ( SizeUnit unit ) : double
unit SizeUnit
return double

GetSmallestPartialSize() public method

Returns a DataSize that is the smallest value which will have a zero whole-number Size component.
public GetSmallestPartialSize ( SizeUnit unit = null ) : DataSize
unit SizeUnit When set to the result will be a B type, when set to the result will be a iB type. If set to null the same base unit as the source value will be used.
return DataSize

IsSame() public method

public IsSame ( DataSize comparison ) : bool
comparison DataSize
return bool

IsSame() public static method

public static IsSame ( DataSize left, DataSize right ) : bool
left DataSize
right DataSize
return bool

ToString() public method

public ToString ( ) : string
return string

ToString() public method

public ToString ( SizeUnit unit ) : string
unit SizeUnit
return string

ToString() public method

public ToString ( string numberFormat ) : string
numberFormat string
return string

ToString() public method

public ToString ( string numberFormat, SizeUnit unit ) : string
numberFormat string
unit SizeUnit
return string

operator() public static method

public static operator ( ) : DataSize
return DataSize

operator() public static method

public static operator ( ) : bool
return bool