Record Class SimpleDialogAction

java.lang.Object
java.lang.Record
net.minecraft.dialog.action.SimpleDialogAction
Record Components:
value -
All Implemented Interfaces:
DialogAction

public record SimpleDialogAction(ClickEvent value) extends Record implements DialogAction
Mappings:
Namespace Name
named net/minecraft/dialog/action/SimpleDialogAction
intermediary net/minecraft/class_11525
official asi
named value
intermediary comp_4399
official c
  • Field Details

    • value

      private final ClickEvent value
      The field for the value record component.
    • CODECS

      public static final Map<ClickEvent.Action,com.mojang.serialization.MapCodec<SimpleDialogAction>> CODECS
      Mappings:
      Namespace Name Mixin selector
      named CODECS Lnet/minecraft/dialog/action/SimpleDialogAction;CODECS:Ljava/util/Map;
      intermediary field_60977 Lnet/minecraft/class_11525;field_60977:Ljava/util/Map;
      official b Lasi;b:Ljava/util/Map;
  • Constructor Details

    • SimpleDialogAction

      public SimpleDialogAction(ClickEvent clickEvent)
  • Method Details

    • getCodec

      public com.mojang.serialization.MapCodec<SimpleDialogAction> getCodec()
      Specified by:
      getCodec in interface DialogAction
      Mappings:
      Namespace Name Mixin selector
      named getCodec Lnet/minecraft/dialog/action/DialogAction;getCodec()Lcom/mojang/serialization/MapCodec;
      intermediary method_71738 Lnet/minecraft/class_11521;method_71738()Lcom/mojang/serialization/MapCodec;
      official a Lasd;a()Lcom/mojang/serialization/MapCodec;
    • createClickEvent

      public Optional<ClickEvent> createClickEvent(Map<String,DialogAction.ValueGetter> valueGetters)
      Specified by:
      createClickEvent in interface DialogAction
      Mappings:
      Namespace Name Mixin selector
      named createClickEvent Lnet/minecraft/dialog/action/DialogAction;createClickEvent(Ljava/util/Map;)Ljava/util/Optional;
      intermediary method_72068 Lnet/minecraft/class_11521;method_72068(Ljava/util/Map;)Ljava/util/Optional;
      official a Lasd;a(Ljava/util/Map;)Ljava/util/Optional;
    • 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.
    • value

      public ClickEvent value()
      Returns the value of the value record component.
      Returns:
      the value of the value record component