C# Class DoubleExtension, Adnc

显示文件 Open project: AlphaYu/Adnc Class Usage Examples

Public Methods

Method Description
Ceiling ( double @this ) : int

Returns the smallest integral value that is greater than or equal to the specified double-precision floating- point number.

Floor ( double @this ) : int

Returns the largest integer less than or equal to the specified double-precision floating-point number.

InRange ( double @this, double minValue, double maxValue ) : bool

A T extension method that check if the value is between inclusively the minValue and maxValue.

ToLong ( double @this ) : long

Method Details

Ceiling() public static method

Returns the smallest integral value that is greater than or equal to the specified double-precision floating- point number.
public static Ceiling ( double @this ) : int
@this double
return int

Floor() public static method

Returns the largest integer less than or equal to the specified double-precision floating-point number.
public static Floor ( double @this ) : int
@this double
return int

InRange() public static method

A T extension method that check if the value is between inclusively the minValue and maxValue.
public static InRange ( double @this, double minValue, double maxValue ) : bool
@this double
minValue double The minimum value.
maxValue double The maximum value.
return bool

ToLong() public static method

public static ToLong ( double @this ) : long
@this double
return long