Record Class FloatProvider.ClampedNormal
java.lang.Object
java.lang.Record
dev.wyck.wrapper.worldgen.valueproviders.FloatProvider.ClampedNormal
- All Implemented Interfaces:
Wrapper, FloatProvider
- Enclosing interface:
FloatProvider
@AsOf("2.3.0")
public static record FloatProvider.ClampedNormal(float mean, float deviation, float min, float max)
extends Record
implements FloatProvider
- Since:
- 2.3.0
-
Nested Class Summary
Nested classes/interfaces inherited from interface FloatProvider
FloatProvider.ClampedNormal, FloatProvider.Constant, FloatProvider.Factory, FloatProvider.Trapezoid, FloatProvider.UniformNested classes/interfaces inherited from interface Wrapper
Wrapper.Context<C> -
Field Summary
Fields inherited from interface FloatProvider
WIRE -
Constructor Summary
ConstructorsConstructorDescriptionClampedNormal(float mean, float deviation, float min, float max) Creates an instance of aClampedNormalrecord class. -
Method Summary
Modifier and TypeMethodDescriptionfloatReturns the value of thedeviationrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.floatmax()Returns the value of themaxrecord component.floatmaxValue()floatmean()Returns the value of themeanrecord component.floatmin()Returns the value of theminrecord component.floatminValue()final StringtoString()Returns a string representation of this record class.Methods inherited from interface FloatProvider
toMinecraft
-
Constructor Details
-
ClampedNormal
public ClampedNormal(float mean, float deviation, float min, float max) Creates an instance of aClampedNormalrecord class.- Parameters:
mean- the value for themeanrecord componentdeviation- the value for thedeviationrecord componentmin- the value for theminrecord componentmax- the value for themaxrecord component
-
-
Method Details
-
minValue
public float minValue()- Specified by:
minValuein interfaceFloatProvider- Returns:
- the smallest value this provider can yield.
-
maxValue
public float maxValue()- Specified by:
maxValuein interfaceFloatProvider- Returns:
- the largest value this provider can yield.
-
toString
-
hashCode
-
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared with thecomparemethod from their corresponding wrapper classes. -
mean
public float mean()Returns the value of themeanrecord component.- Returns:
- the value of the
meanrecord component
-
deviation
public float deviation()Returns the value of thedeviationrecord component.- Returns:
- the value of the
deviationrecord component
-
min
public float min()Returns the value of theminrecord component.- Returns:
- the value of the
minrecord component
-
max
public float max()Returns the value of themaxrecord component.- Returns:
- the value of the
maxrecord component
-