yarn/mappings/net/minecraft/util/registry/RegistryEntryList.mapping

71 lines
3.5 KiB
Plaintext

CLASS net/minecraft/class_6885 net/minecraft/util/registry/RegistryEntryList
COMMENT A registry entry list is an immutable list of registry entries. This, is either a direct
COMMENT reference to each item, or a reference to a tag. A <strong>tag</strong> is a way
COMMENT to dynamically define a list of registered values. Anything registered in a registry
COMMENT can be tagged, and each registry holds a list of tags it recognizes.
COMMENT
COMMENT <p>This can be iterated directly (i.e. {@code for (RegistryEntry<T> entry : entries)}.
COMMENT Note that this does not implement {@link java.util.Collection}.
COMMENT
COMMENT @see Registry
COMMENT @see RegistryEntry
METHOD method_40239 stream ()Ljava/util/stream/Stream;
COMMENT {@return a stream of registry entries in this list}
METHOD method_40240 get (I)Lnet/minecraft/class_6880;
COMMENT {@return the registry entry at {@code index}}
COMMENT
COMMENT @throws IndexOutOfBoundsException if the index is out of bounds
ARG 1 index
METHOD method_40241 contains (Lnet/minecraft/class_6880;)Z
COMMENT {@return whether {@code entry} is in this list}
ARG 1 entry
METHOD method_40242 of (Ljava/util/List;)Lnet/minecraft/class_6885$class_6886;
COMMENT {@return a new direct list of {@code entries}}
ARG 0 entries
METHOD method_40243 getRandom (Lnet/minecraft/class_5819;)Ljava/util/Optional;
COMMENT {@return a random entry of the list, or an empty optional if this list is empty}
ARG 1 random
METHOD method_40244 of (Ljava/util/function/Function;Ljava/util/List;)Lnet/minecraft/class_6885$class_6886;
COMMENT {@return a new direct list of {@code values} converted to a registry entry with {@code mapper}}
ARG 0 mapper
ARG 1 values
METHOD method_40245 of (Ljava/util/function/Function;[Ljava/lang/Object;)Lnet/minecraft/class_6885$class_6886;
COMMENT {@return a new direct list of {@code values} converted to a registry entry with {@code mapper}}
ARG 0 mapper
ARG 1 values
METHOD method_40246 of ([Lnet/minecraft/class_6880;)Lnet/minecraft/class_6885$class_6886;
COMMENT {@return a new direct list of {@code entries}}
ARG 0 entries
METHOD method_40247 size ()I
COMMENT {@return the number of entries in this list}
METHOD method_40248 getStorage ()Lcom/mojang/datafixers/util/Either;
COMMENT {@return the object that identifies this registry entry list}
COMMENT
COMMENT <p>This is the tag key for a reference list, and the backing list for a direct list.
METHOD method_40560 isOf (Lnet/minecraft/class_2378;)Z
COMMENT {@return whether the list is of entries from {@code registry}}
COMMENT
COMMENT <p>This always returns {@code true} for direct lists.
ARG 1 registry
CLASS class_6886 Direct
COMMENT A direct registry entry list that holds the values directly, instead of using tags.
FIELD field_36457 entries Ljava/util/List;
FIELD field_36458 entrySet Ljava/util/Set;
METHOD <init> (Ljava/util/List;)V
ARG 1 entries
CLASS class_6887 ListBacked
COMMENT An internal implementation of {@link RegistryEntryList}.
METHOD method_40249 getEntries ()Ljava/util/List;
CLASS class_6888 Named
COMMENT A registry entry list that references a tag from the registry.
FIELD field_36459 tag Lnet/minecraft/class_6862;
FIELD field_36460 entries Ljava/util/List;
FIELD field_36633 registry Lnet/minecraft/class_2378;
METHOD <init> (Lnet/minecraft/class_2378;Lnet/minecraft/class_6862;)V
ARG 1 registry
ARG 2 tag
METHOD method_40250 copyOf (Ljava/util/List;)V
ARG 1 entries
METHOD method_40251 getTag ()Lnet/minecraft/class_6862;
COMMENT {@return the tag key that this list references}