Class FloatGenerator
- Namespace
- Hegel
- Assembly
- Hegel.dll
Draws 32-bit floating-point numbers.
public sealed class FloatGenerator : ValueGenerator<float>
- Inheritance
-
FloatGenerator
- Inherited Members
Properties
Label
The span label the engine files this generator's draws under. Defaults to a label derived from the class's full name.
public override ulong Label { get; }
Property Value
Methods
AllowInfinity(bool)
Whether infinities may be drawn (by default, only towards an unbounded side).
public FloatGenerator AllowInfinity(bool allow)
Parameters
allowbool
Returns
AllowNan(bool)
Whether NaN may be drawn (by default, only when unbounded).
public FloatGenerator AllowNan(bool allow)
Parameters
allowbool
Returns
AllowSubnormal(bool)
Whether subnormal numbers may be drawn (by default, when the range contains them).
public FloatGenerator AllowSubnormal(bool allow)
Parameters
allowbool
Returns
DoDraw(TestCase)
Draw one value. Called inside a span labelled Label: draw from another generator through DrawSilent<T>(Generator<T>), which opens its span, rather than by calling its hook.
protected override float DoDraw(TestCase tc)
Parameters
tcTestCase
Returns
Max(float)
At most max.
public FloatGenerator Max(float max)
Parameters
maxfloat
Returns
MaxExclusive(float)
Less than max.
public FloatGenerator MaxExclusive(float max)
Parameters
maxfloat
Returns
Min(float)
At least min.
public FloatGenerator Min(float min)
Parameters
minfloat
Returns
MinExclusive(float)
More than min.
public FloatGenerator MinExclusive(float min)
Parameters
minfloat