Class Pool<E extends Weighted>

java.lang.Object
net.minecraft.util.collection.Pool<E>
Direct Known Subclasses:
DataPool

public class Pool<E extends Weighted> extends Object
Mappings:
Namespace Name
named net/minecraft/util/collection/Pool
intermediary net/minecraft/class_6012
official bpf
  • Field Details

    • totalWeight

      private final int totalWeight
      Mappings:
      Namespace Name Mixin selector
      named totalWeight Lnet/minecraft/util/collection/Pool;totalWeight:I
      intermediary field_29934 Lnet/minecraft/class_6012;field_29934:I
      official a Lbpf;a:I
    • entries

      private final ImmutableList<E extends Weighted> entries
      Mappings:
      Namespace Name Mixin selector
      named entries Lnet/minecraft/util/collection/Pool;entries:Lcom/google/common/collect/ImmutableList;
      intermediary field_29935 Lnet/minecraft/class_6012;field_29935:Lcom/google/common/collect/ImmutableList;
      official b Lbpf;b:Lcom/google/common/collect/ImmutableList;
  • Constructor Details

    • Pool

      Pool(List<? extends E> entries)
      Mappings:
      Namespace Name Mixin selector
      named <init> Lnet/minecraft/util/collection/Pool;<init>(Ljava/util/List;)V
      intermediary <init> Lnet/minecraft/class_6012;<init>(Ljava/util/List;)V
      official <init> Lbpf;<init>(Ljava/util/List;)V
  • Method Details

    • empty

      public static <E extends Weighted> Pool<E> empty()
      Mappings:
      Namespace Name Mixin selector
      named empty Lnet/minecraft/util/collection/Pool;empty()Lnet/minecraft/util/collection/Pool;
      intermediary method_34990 Lnet/minecraft/class_6012;method_34990()Lnet/minecraft/class_6012;
      official c Lbpf;c()Lbpf;
    • of

      @SafeVarargs public static <E extends Weighted> Pool<E> of(E[] entries)
      Mappings:
      Namespace Name Mixin selector
      named of Lnet/minecraft/util/collection/Pool;of([Lnet/minecraft/util/collection/Weighted;)Lnet/minecraft/util/collection/Pool;
      intermediary method_34989 Lnet/minecraft/class_6012;method_34989([Lnet/minecraft/class_6008;)Lnet/minecraft/class_6012;
      official a Lbpf;a([Lbpd;)Lbpf;
    • of

      public static <E extends Weighted> Pool<E> of(List<E> entries)
      Mappings:
      Namespace Name Mixin selector
      named of Lnet/minecraft/util/collection/Pool;of(Ljava/util/List;)Lnet/minecraft/util/collection/Pool;
      intermediary method_34988 Lnet/minecraft/class_6012;method_34988(Ljava/util/List;)Lnet/minecraft/class_6012;
      official a Lbpf;a(Ljava/util/List;)Lbpf;
    • isEmpty

      public boolean isEmpty()
      Mappings:
      Namespace Name Mixin selector
      named isEmpty Lnet/minecraft/util/collection/Pool;isEmpty()Z
      intermediary method_34993 Lnet/minecraft/class_6012;method_34993()Z
      official d Lbpf;d()Z
    • getOrEmpty

      public Optional<E> getOrEmpty(Random random)
      Mappings:
      Namespace Name Mixin selector
      named getOrEmpty Lnet/minecraft/util/collection/Pool;getOrEmpty(Lnet/minecraft/util/math/random/Random;)Ljava/util/Optional;
      intermediary method_34992 Lnet/minecraft/class_6012;method_34992(Lnet/minecraft/class_5819;)Ljava/util/Optional;
      official b Lbpf;b(Layw;)Ljava/util/Optional;
    • getEntries

      public List<E> getEntries()
      Mappings:
      Namespace Name Mixin selector
      named getEntries Lnet/minecraft/util/collection/Pool;getEntries()Ljava/util/List;
      intermediary method_34994 Lnet/minecraft/class_6012;method_34994()Ljava/util/List;
      official e Lbpf;e()Ljava/util/List;
    • createCodec

      public static <E extends Weighted> com.mojang.serialization.Codec<Pool<E>> createCodec(com.mojang.serialization.Codec<E> entryCodec)
      Mappings:
      Namespace Name Mixin selector
      named createCodec Lnet/minecraft/util/collection/Pool;createCodec(Lcom/mojang/serialization/Codec;)Lcom/mojang/serialization/Codec;
      intermediary method_34991 Lnet/minecraft/class_6012;method_34991(Lcom/mojang/serialization/Codec;)Lcom/mojang/serialization/Codec;
      official c Lbpf;c(Lcom/mojang/serialization/Codec;)Lcom/mojang/serialization/Codec;
    • equals

      public boolean equals(@Nullable @Nullable Object o)
      Overrides:
      equals in class Object
      Mappings:
      Namespace Name Mixin selector
      named equals Lnet/minecraft/util/collection/Pool;equals(Ljava/lang/Object;)Z
      intermediary equals Lnet/minecraft/class_6012;equals(Ljava/lang/Object;)Z
      official equals Lbpf;equals(Ljava/lang/Object;)Z
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object