Class DoubleGenerator

All Implemented Interfaces:
Generator, TypedGenerator<Double>

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

    • DEFAULT_VALUE

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

    • DoubleGenerator

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

    • defaultValue

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

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

      public static double randomDouble()
      Generates a random double between Double.NEGATIVE_INFINITY and Double.POSITIVE_INFINITY both included.
      Returns:
      A random double value
    • randomFiniteDouble

      public static double randomFiniteDouble()
      Generates a random double between Double.NEGATIVE_INFINITY and Double.POSITIVE_INFINITY both excluded.
      Returns:
      A random double value