Record Class CubicSpline.Multipoint.Point<I extends BoundedFloatFunction<?>>
java.lang.Object
java.lang.Record
net.minecraft.util.CubicSpline.Multipoint.Point<I>
- Enclosing class:
CubicSpline.Multipoint<I extends BoundedFloatFunction<?>>
private static record CubicSpline.Multipoint.Point<I extends BoundedFloatFunction<?>>(float location, CubicSpline<I extends BoundedFloatFunction<?>> value, float derivative)
extends Record
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final floatThe field for thederivativerecord component.private final floatThe field for thelocationrecord component.private final CubicSpline<I> The field for thevaluerecord component. -
Constructor Summary
ConstructorsModifierConstructorDescriptionprivatePoint(float location, CubicSpline<I> value, float derivative) Creates an instance of aPointrecord class. -
Method Summary
Modifier and TypeMethodDescriptionstatic <I extends BoundedFloatFunction<?>>
com.mojang.serialization.Codec<CubicSpline.Multipoint.Point<I>> codec(com.mojang.serialization.Codec<CubicSpline<I>> subSplineCodec) floatReturns the value of thederivativerecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.floatlocation()Returns the value of thelocationrecord component.final StringtoString()Returns a string representation of this record class.value()Returns the value of thevaluerecord component.
-
Field Details
-
location
private final float locationThe field for thelocationrecord component. -
value
The field for thevaluerecord component. -
derivative
private final float derivativeThe field for thederivativerecord component.
-
-
Constructor Details
-
Point
Creates an instance of aPointrecord class.- Parameters:
location- the value for thelocationrecord componentvalue- the value for thevaluerecord componentderivative- the value for thederivativerecord component
-
-
Method Details
-
codec
public static <I extends BoundedFloatFunction<?>> com.mojang.serialization.Codec<CubicSpline.Multipoint.Point<I>> codec(com.mojang.serialization.Codec<CubicSpline<I>> subSplineCodec) -
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. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with thecomparemethod from their corresponding wrapper classes. -
location
public float location()Returns the value of thelocationrecord component.- Returns:
- the value of the
locationrecord component
-
value
Returns the value of thevaluerecord component.- Returns:
- the value of the
valuerecord component
-
derivative
public float derivative()Returns the value of thederivativerecord component.- Returns:
- the value of the
derivativerecord component
-