Record Class CommandTreeS2CPacket.LiteralNode

java.lang.Object
java.lang.Record
net.minecraft.network.packet.s2c.play.CommandTreeS2CPacket.LiteralNode
Record Components:
literal -
All Implemented Interfaces:
CommandTreeS2CPacket.SuggestableNode
Enclosing class:
CommandTreeS2CPacket

private static record CommandTreeS2CPacket.LiteralNode(String literal) extends Record implements CommandTreeS2CPacket.SuggestableNode
Mappings:
Namespace Name
named net/minecraft/network/packet/s2c/play/CommandTreeS2CPacket$LiteralNode
intermediary net/minecraft/class_2641$class_7233
official adi$c
named literal
intermediary comp_4291
official a
  • Field Details

    • literal

      private final String literal
      The field for the literal record component.
  • Constructor Details

    • LiteralNode

      LiteralNode(String literal)
      Creates an instance of a LiteralNode record class.
      Parameters:
      literal - the value for the literal record component
  • Method Details

    • createArgumentBuilder

      public <S> com.mojang.brigadier.builder.ArgumentBuilder<S,?> createArgumentBuilder(CommandRegistryAccess commandRegistryAccess, CommandTreeS2CPacket.NodeFactory<S> nodeFactory)
      Specified by:
      createArgumentBuilder in interface CommandTreeS2CPacket.SuggestableNode
      Mappings:
      Namespace Name Mixin selector
      named createArgumentBuilder Lnet/minecraft/network/packet/s2c/play/CommandTreeS2CPacket$SuggestableNode;createArgumentBuilder(Lnet/minecraft/command/CommandRegistryAccess;Lnet/minecraft/network/packet/s2c/play/CommandTreeS2CPacket$NodeFactory;)Lcom/mojang/brigadier/builder/ArgumentBuilder;
      intermediary method_42070 Lnet/minecraft/class_2641$class_7235;method_42070(Lnet/minecraft/class_7157;Lnet/minecraft/class_2641$class_11408;)Lcom/mojang/brigadier/builder/ArgumentBuilder;
      official a Ladi$g;a(Leg;Ladi$d;)Lcom/mojang/brigadier/builder/ArgumentBuilder;
    • write

      public void write(PacketByteBuf buf)
      Specified by:
      write in interface CommandTreeS2CPacket.SuggestableNode
      Mappings:
      Namespace Name Mixin selector
      named write Lnet/minecraft/network/packet/s2c/play/CommandTreeS2CPacket$SuggestableNode;write(Lnet/minecraft/network/PacketByteBuf;)V
      intermediary method_42071 Lnet/minecraft/class_2641$class_7235;method_42071(Lnet/minecraft/class_2540;)V
      official a Ladi$g;a(Lwg;)V
    • 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 object)
      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:
      object - the object with which to compare
      Returns:
      true if this object is the same as the object argument; false otherwise.
    • literal

      public String literal()
      Returns the value of the literal record component.
      Returns:
      the value of the literal record component