Record Class GuiMessageTag

java.lang.Object
java.lang.Record
net.minecraft.client.GuiMessageTag

public record GuiMessageTag(int indicatorColor, @Nullable GuiMessageTag.Icon icon, @Nullable Component text, @Nullable String logTag) extends Record
  • Field Details

    • indicatorColor

      private final int indicatorColor
      The field for the indicatorColor record component.
    • icon

      @Nullable private final GuiMessageTag.Icon icon
      The field for the icon record component.
    • text

      @Nullable private final Component text
      The field for the text record component.
    • logTag

      @Nullable private final String logTag
      The field for the logTag record component.
    • SYSTEM_TEXT

      private static final Component SYSTEM_TEXT
    • SYSTEM_TEXT_SINGLE_PLAYER

      private static final Component SYSTEM_TEXT_SINGLE_PLAYER
    • CHAT_NOT_SECURE_TEXT

      private static final Component CHAT_NOT_SECURE_TEXT
    • CHAT_MODIFIED_TEXT

      private static final Component CHAT_MODIFIED_TEXT
    • CHAT_NOT_SECURE_INDICATOR_COLOR

      private static final int CHAT_NOT_SECURE_INDICATOR_COLOR
      See Also:
    • CHAT_MODIFIED_INDICATOR_COLOR

      private static final int CHAT_MODIFIED_INDICATOR_COLOR
      See Also:
    • SYSTEM

      private static final GuiMessageTag SYSTEM
    • SYSTEM_SINGLE_PLAYER

      private static final GuiMessageTag SYSTEM_SINGLE_PLAYER
    • CHAT_NOT_SECURE

      private static final GuiMessageTag CHAT_NOT_SECURE
    • TEXTURE_LOCATION

      static final ResourceLocation TEXTURE_LOCATION
  • Constructor Details

    • GuiMessageTag

      public GuiMessageTag(int indicatorColor, @Nullable GuiMessageTag.Icon icon, @Nullable Component text, @Nullable String logTag)
      Creates an instance of a GuiMessageTag record class.
      Parameters:
      indicatorColor - the value for the indicatorColor record component
      icon - the value for the icon record component
      text - the value for the text record component
      logTag - the value for the logTag record component
  • Method Details

    • system

      public static GuiMessageTag system()
    • systemSinglePlayer

      public static GuiMessageTag systemSinglePlayer()
    • chatNotSecure

      public static GuiMessageTag chatNotSecure()
    • chatModified

      public static GuiMessageTag chatModified(String p_242878_)
    • 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. Reference components are compared with Objects::equals(Object,Object); primitive components are compared with '=='.
      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.
    • indicatorColor

      public int indicatorColor()
      Returns the value of the indicatorColor record component.
      Returns:
      the value of the indicatorColor record component
    • icon

      @Nullable public GuiMessageTag.Icon icon()
      Returns the value of the icon record component.
      Returns:
      the value of the icon record component
    • text

      @Nullable public Component text()
      Returns the value of the text record component.
      Returns:
      the value of the text record component
    • logTag

      @Nullable public String logTag()
      Returns the value of the logTag record component.
      Returns:
      the value of the logTag record component