Interface UniformFloat

All Superinterfaces:
Comparable<ValueProvider>, FloatProvider, ValueProvider, Wrapper

@NullMarked @AsOf("3.0.0") public interface UniformFloat extends FloatProvider
Uniform float providers sample a range between FloatProvider.minInclusive() (inclusive) and maxExclusive() (exclusive), returning a single, uniformly random value. Note the upper bound is exclusive here, unlike the int provider family.
Since:
3.0.0
See Also:
  • Method Details

    • maxExclusive

      @AsOf("3.0.0") float maxExclusive()
      The exclusive upper bound of the range.
      Returns:
      the exclusive upper bound
      Since:
      3.0.0
    • maxInclusive

      @AsOf("3.0.0") default float maxInclusive()
      Description copied from interface: FloatProvider
      The largest value this provider can yield.
      Specified by:
      maxInclusive in interface FloatProvider
      Returns:
      the largest value this provider can yield.
    • toBuilder

      @AsOf("3.0.0") default UniformFloat.Builder toBuilder()
      Converts this object back to a builder.
      Returns:
      a builder with the same values as this object
      Since:
      3.0.0
    • of

      @AsOf("3.0.0") static UniformFloat of(float min, float max)
      Creates a new uniform float provider.
      Parameters:
      min - the minimum value (inclusive)
      max - the maximum value (exclusive)
      Returns:
      the uniform float provider
      Since:
      3.0.0
    • builder

      @AsOf("3.0.0") static UniformFloat.Builder builder()
      Creates a new builder.
      Returns:
      a new builder
      Since:
      3.0.0