Class NumberExtensions

Namespace
Elegy.Common.Extensions
Assembly
Elegy.Common.dll

Extensions for floats and doubles.

public static class NumberExtensions
Inheritance
NumberExtensions
Inherited Members

Methods

Filter<T>(T, bool)

Acts like a switch for a flag, backed by a boolean.

public static T Filter<T>(this T e, bool x) where T : Enum

Parameters

e T
x bool

Returns

T

Type Parameters

T

ToDegrees(double)

Returns this radian angle in degrees.

public static double ToDegrees(this double x)

Parameters

x double

Returns

double

ToDegrees(float)

Returns this radian angle in degrees.

public static float ToDegrees(this float x)

Parameters

x float

Returns

float

ToRadians(double)

Returns this degree angle in radians.

public static double ToRadians(this double x)

Parameters

x double

Returns

double

ToRadians(float)

Returns this degree angle in radians.

public static float ToRadians(this float x)

Parameters

x float

Returns

float