Package appeng.api.implementations.items
Record Class MemoryCardColors
java.lang.Object
java.lang.Record
appeng.api.implementations.items.MemoryCardColors
- Record Components:
top1
-top2
-top3
-top4
-bottom1
-bottom2
-bottom3
-bottom4
-
public record MemoryCardColors(AEColor top1, AEColor top2, AEColor top3, AEColor top4, AEColor bottom1, AEColor bottom2, AEColor bottom3, AEColor bottom4)
extends Record
Describes the custom colors to show o n a memory card item.
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final com.mojang.serialization.Codec
<MemoryCardColors> static final MemoryCardColors
static net.minecraft.network.codec.StreamCodec
<net.minecraft.network.FriendlyByteBuf, MemoryCardColors> -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbottom1()
Returns the value of thebottom1
record component.bottom2()
Returns the value of thebottom2
record component.bottom3()
Returns the value of thebottom3
record component.bottom4()
Returns the value of thebottom4
record component.final boolean
Indicates whether some other object is "equal to" this one.get
(int x, int y) final int
hashCode()
Returns a hash code value for this object.top1()
Returns the value of thetop1
record component.top2()
Returns the value of thetop2
record component.top3()
Returns the value of thetop3
record component.top4()
Returns the value of thetop4
record component.final String
toString()
Returns a string representation of this record class.
-
Field Details
-
CODEC
-
STREAM_CODEC
public static net.minecraft.network.codec.StreamCodec<net.minecraft.network.FriendlyByteBuf,MemoryCardColors> STREAM_CODEC -
DEFAULT
-
-
Constructor Details
-
MemoryCardColors
public MemoryCardColors(AEColor top1, AEColor top2, AEColor top3, AEColor top4, AEColor bottom1, AEColor bottom2, AEColor bottom3, AEColor bottom4) Creates an instance of aMemoryCardColors
record class.- Parameters:
top1
- the value for thetop1
record componenttop2
- the value for thetop2
record componenttop3
- the value for thetop3
record componenttop4
- the value for thetop4
record componentbottom1
- the value for thebottom1
record componentbottom2
- the value for thebottom2
record componentbottom3
- the value for thebottom3
record componentbottom4
- the value for thebottom4
record component
-
-
Method Details
-
get
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
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)
. -
top1
Returns the value of thetop1
record component.- Returns:
- the value of the
top1
record component
-
top2
Returns the value of thetop2
record component.- Returns:
- the value of the
top2
record component
-
top3
Returns the value of thetop3
record component.- Returns:
- the value of the
top3
record component
-
top4
Returns the value of thetop4
record component.- Returns:
- the value of the
top4
record component
-
bottom1
Returns the value of thebottom1
record component.- Returns:
- the value of the
bottom1
record component
-
bottom2
Returns the value of thebottom2
record component.- Returns:
- the value of the
bottom2
record component
-
bottom3
Returns the value of thebottom3
record component.- Returns:
- the value of the
bottom3
record component
-
bottom4
Returns the value of thebottom4
record component.- Returns:
- the value of the
bottom4
record component
-