Record Class SimpleEasingSerializer
java.lang.Object
java.lang.Record
net.thewinnt.cutscenes.easing.serializers.SimpleEasingSerializer
- All Implemented Interfaces:
EasingSerializer<SimpleEasing>
public record SimpleEasingSerializer(SimpleEasing easing, com.mojang.serialization.MapCodec<SimpleEasing> codec)
extends Record
implements EasingSerializer<SimpleEasing>
-
Field Summary
Fields inherited from interface net.thewinnt.cutscenes.easing.EasingSerializer
ABS, ACOS, ADD, ASIN, ATAN, ATAN2, CHAIN, CLAMP, COLOR, COMPOUND, CONSTANT, COS, CUBE, DIV, DOUBLE_ARGUMENT_EASINGS, IN_BACK, IN_BOUNCE, IN_CIRC, IN_CUBIC, IN_ELASTIC, IN_EXPO, IN_OUT_BACK, IN_OUT_BOUNCE, IN_OUT_CIRC, IN_OUT_CUBIC, IN_OUT_ELASTIC, IN_OUT_EXPO, IN_OUT_QUAD, IN_OUT_QUART, IN_OUT_QUINT, IN_OUT_SINE, IN_QUAD, IN_QUART, IN_QUINT, IN_SINE, LEGACY_COMPAT, LERP, LINEAR, MAX, MIN, MOD, MUL, OUT_BACK, OUT_BOUNCE, OUT_CIRC, OUT_CUBIC, OUT_ELASTIC, OUT_EXPO, OUT_QUAD, OUT_QUART, OUT_QUINT, OUT_SINE, POW, SIMPLE_EASINGS, SIN, SINGLE_ARGUMENT_EASINGS, SPLINE, SQRT, SQUARE, SUBTRACT, TAN, TO_DEGREES, TO_RADIANS -
Constructor Summary
ConstructorsConstructorDescriptionSimpleEasingSerializer(SimpleEasing easing) SimpleEasingSerializer(SimpleEasing easing, com.mojang.serialization.MapCodec<SimpleEasing> codec) Creates an instance of aSimpleEasingSerializerrecord class. -
Method Summary
Modifier and TypeMethodDescriptioncom.mojang.serialization.MapCodec<SimpleEasing> codec()Returns the value of thecodecrecord component.easing()Returns the value of theeasingrecord component.final booleanIndicates whether some other object is "equal to" this one.fromJSON(com.google.gson.JsonObject json) fromJSON(com.google.gson.JsonObject json, LoadResolver<Easing> context) fromNetwork(net.minecraft.network.FriendlyByteBuf buf) final inthashCode()Returns a hash code value for this object.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
SimpleEasingSerializer
-
SimpleEasingSerializer
public SimpleEasingSerializer(SimpleEasing easing, com.mojang.serialization.MapCodec<SimpleEasing> codec) Creates an instance of aSimpleEasingSerializerrecord class.- Parameters:
easing- the value for theeasingrecord componentcodec- the value for thecodecrecord component
-
-
Method Details
-
fromNetwork
- Specified by:
fromNetworkin interfaceEasingSerializer<SimpleEasing>
-
fromJSON
- Specified by:
fromJSONin interfaceEasingSerializer<SimpleEasing>
-
fromJSON
- Specified by:
fromJSONin interfaceEasingSerializer<SimpleEasing>
-
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 withObjects::equals(Object,Object). -
easing
Returns the value of theeasingrecord component.- Returns:
- the value of the
easingrecord component
-
codec
Returns the value of thecodecrecord component.- Specified by:
codecin interfaceEasingSerializer<SimpleEasing>- Returns:
- the value of the
codecrecord component
-