Class FloatGenerator

All Implemented Interfaces:
Generator, TypedGenerator<Float>

@API(status=STABLE, since="0.1") @Priority(-1000) public class FloatGenerator extends AbstractPrimitiveGenerator<Float>
Generator of float and Float values.
Since:
0.1
Version:
1.0, 2022-10
Author:
(w) Iker Hernaez
  • Field Details

    • DEFAULT_VALUE

      public static final float DEFAULT_VALUE
      The default value.
      See Also:
  • Constructor Details

    • FloatGenerator

      public FloatGenerator()
      Creates a new instance.
  • Method Details

    • defaultValue

      @NotNull public @NotNull Float defaultValue()
      Returns the default value of the supported type.
      Returns:
      The default value.
    • randomValue

      @NotNull public @NotNull Float randomValue()
      Returns a random value of the supported type.
      Returns:
      A random value.
    • randomFloat

      public static float randomFloat()
      Generates a random float between Float.NEGATIVE_INFINITY and Float.POSITIVE_INFINITY both included.
      Returns:
      A random float value
    • randomFiniteFloat

      public static float randomFiniteFloat()
      Generates a random float between Float.NEGATIVE_INFINITY and Float.POSITIVE_INFINITY both excluded.
      Returns:
      A random float value