Class BaseTypeExtensions
- Namespace
- ReFuel
- Assembly
- ReFuel.Common.dll
public static class BaseTypeExtensions
- Inheritance
-
BaseTypeExtensions
- Inherited Members
Methods
GetStableHashCode(string)
public static int GetStableHashCode(this string str)
Parameters
str
string
Returns
IsNear(double, double, double, double)
Python's math.isclose()
public static bool IsNear(this double a, double b, double relativeTolerance = 1E-09, double absoluteTolerance = 0)
Parameters
a
doubleDouble A
b
doubleDouble B
relativeTolerance
doubleTolerance relative to the double values.
absoluteTolerance
doubleAbsolute tolerance.
Returns
- bool
True if the values are near.
IsNear(float, float, float, float)
Python's math.isclose()
public static bool IsNear(this float a, float b, float relativeTolerance = 1E-09, float absoluteTolerance = 0)
Parameters
a
floatFloat A
b
floatFloat B
relativeTolerance
floatTolerance relative to the float values.
absoluteTolerance
floatAbsolute tolerance.
Returns
- bool
True if the values are near.