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 Details

    • CODEC

      public static final com.mojang.serialization.Codec<MemoryCardColors> CODEC
    • STREAM_CODEC

      public static net.minecraft.network.codec.StreamCodec<net.minecraft.network.FriendlyByteBuf,MemoryCardColors> STREAM_CODEC
    • DEFAULT

      public static final MemoryCardColors 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 a MemoryCardColors record class.
      Parameters:
      top1 - the value for the top1 record component
      top2 - the value for the top2 record component
      top3 - the value for the top3 record component
      top4 - the value for the top4 record component
      bottom1 - the value for the bottom1 record component
      bottom2 - the value for the bottom2 record component
      bottom3 - the value for the bottom3 record component
      bottom4 - the value for the bottom4 record component
  • Method Details

    • get

      public AEColor get(int x, int y)
    • toString

      public final String 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.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • 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.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      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 Objects::equals(Object,Object).
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • top1

      public AEColor top1()
      Returns the value of the top1 record component.
      Returns:
      the value of the top1 record component
    • top2

      public AEColor top2()
      Returns the value of the top2 record component.
      Returns:
      the value of the top2 record component
    • top3

      public AEColor top3()
      Returns the value of the top3 record component.
      Returns:
      the value of the top3 record component
    • top4

      public AEColor top4()
      Returns the value of the top4 record component.
      Returns:
      the value of the top4 record component
    • bottom1

      public AEColor bottom1()
      Returns the value of the bottom1 record component.
      Returns:
      the value of the bottom1 record component
    • bottom2

      public AEColor bottom2()
      Returns the value of the bottom2 record component.
      Returns:
      the value of the bottom2 record component
    • bottom3

      public AEColor bottom3()
      Returns the value of the bottom3 record component.
      Returns:
      the value of the bottom3 record component
    • bottom4

      public AEColor bottom4()
      Returns the value of the bottom4 record component.
      Returns:
      the value of the bottom4 record component