Record Class KeyframeTrackSampler.Segment<T>
java.lang.Object
java.lang.Record
net.minecraft.util.KeyframeTrackSampler.Segment<T>
- Enclosing class:
KeyframeTrackSampler<T>
private static record KeyframeTrackSampler.Segment<T>(EasingType easing, T fromValue, int fromTicks, T toValue, int toTicks)
extends Record
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final EasingTypeThe field for theeasingrecord component.private final intThe field for thefromTicksrecord component.private final TThe field for thefromValuerecord component.private final intThe field for thetoTicksrecord component.private final TThe field for thetoValuerecord component. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioneasing()Returns the value of theeasingrecord component.final booleanIndicates whether some other object is "equal to" this one.intReturns the value of thefromTicksrecord component.Returns the value of thefromValuerecord component.final inthashCode()Returns a hash code value for this object.final StringtoString()Returns a string representation of this record class.inttoTicks()Returns the value of thetoTicksrecord component.toValue()Returns the value of thetoValuerecord component.
-
Field Details
-
easing
The field for theeasingrecord component. -
fromValue
The field for thefromValuerecord component. -
fromTicks
private final int fromTicksThe field for thefromTicksrecord component. -
toValue
The field for thetoValuerecord component. -
toTicks
private final int toTicksThe field for thetoTicksrecord component.
-
-
Constructor Details
-
Segment
-
Segment
Creates an instance of aSegmentrecord class.- Parameters:
easing- the value for theeasingrecord componentfromValue- the value for thefromValuerecord componentfromTicks- the value for thefromTicksrecord componenttoValue- the value for thetoValuerecord componenttoTicks- the value for thetoTicksrecord component
-
-
Method Details
-
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. -
easing
Returns the value of theeasingrecord component.- Returns:
- the value of the
easingrecord component
-
fromValue
Returns the value of thefromValuerecord component.- Returns:
- the value of the
fromValuerecord component
-
fromTicks
public int fromTicks()Returns the value of thefromTicksrecord component.- Returns:
- the value of the
fromTicksrecord component
-
toValue
Returns the value of thetoValuerecord component.- Returns:
- the value of the
toValuerecord component
-
toTicks
public int toTicks()Returns the value of thetoTicksrecord component.- Returns:
- the value of the
toTicksrecord component
-