Record Class ListModifier.Insert

java.lang.Object
java.lang.Record
net.minecraft.loot.function.ListModifier.Insert
Record Components:
offset -
All Implemented Interfaces:
ListModifier
Enclosing interface:
ListModifier

public static record ListModifier.Insert(int offset) extends Record implements ListModifier
Mappings:
Namespace Name
official epn$b
intermediary net/minecraft/class_9368$class_9370
named net/minecraft/loot/function/ListModifier$Insert
official b
intermediary comp_2463
named offset
  • Field Details

    • offset

      private final int offset
      The field for the offset record component.
    • LOGGER

      private static final Logger LOGGER
      Mappings:
      Namespace Name Mixin selector
      official c Lepn$b;c:Lorg/slf4j/Logger;
      intermediary field_49851 Lnet/minecraft/class_9368$class_9370;field_49851:Lorg/slf4j/Logger;
      named LOGGER Lnet/minecraft/loot/function/ListModifier$Insert;LOGGER:Lorg/slf4j/Logger;
    • MAP_CODEC

      public static final com.mojang.serialization.MapCodec<ListModifier.Insert> MAP_CODEC
      Mappings:
      Namespace Name Mixin selector
      official a Lepn$b;a:Lcom/mojang/serialization/MapCodec;
      intermediary field_49850 Lnet/minecraft/class_9368$class_9370;field_49850:Lcom/mojang/serialization/MapCodec;
      named MAP_CODEC Lnet/minecraft/loot/function/ListModifier$Insert;MAP_CODEC:Lcom/mojang/serialization/MapCodec;
  • Constructor Details

    • Insert

      public Insert(int int2)
  • Method Details

    • getMode

      public ListModifier.Mode getMode()
      Specified by:
      getMode in interface ListModifier
      Mappings:
      Namespace Name Mixin selector
      official a Lepn;a()Lepn$e;
      intermediary method_58191 Lnet/minecraft/class_9368;method_58191()Lnet/minecraft/class_9368$class_9373;
      named getMode Lnet/minecraft/loot/function/ListModifier;getMode()Lnet/minecraft/loot/function/ListModifier$Mode;
    • apply

      public <T> List<T> apply(List<T> base, List<T> toApply, int maxSize)
      Specified by:
      apply in interface ListModifier
      Mappings:
      Namespace Name Mixin selector
      official a Lepn;a(Ljava/util/List;Ljava/util/List;I)Ljava/util/List;
      intermediary method_58192 Lnet/minecraft/class_9368;method_58192(Ljava/util/List;Ljava/util/List;I)Ljava/util/List;
      named apply Lnet/minecraft/loot/function/ListModifier;apply(Ljava/util/List;Ljava/util/List;I)Ljava/util/List;
    • 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 '=='.
      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.
    • offset

      public int offset()
      Returns the value of the offset record component.
      Returns:
      the value of the offset record component