Package net.minecraft.world.chunk
Class BiMapPalette<T>
java.lang.Object
net.minecraft.world.chunk.BiMapPalette<T>
- All Implemented Interfaces:
Palette<T>
public class BiMapPalette<T> extends Object implements Palette<T>
- Mappings:
Namespace Name official cju
intermediary net/minecraft/class_2814
named net/minecraft/world/chunk/BiMapPalette
-
Field Summary
Fields Modifier and Type Field Description private Function<CompoundTag,T>
elementDeserializer
private Function<T,CompoundTag>
elementSerializer
private IdList<T>
idList
private int
indexBits
private Int2ObjectBiMap<T>
map
private PaletteResizeListener<T>
resizeHandler
-
Constructor Summary
Constructors Constructor Description BiMapPalette(IdList<T> idList, int indexBits, PaletteResizeListener<T> resizeHandler, Function<CompoundTag,T> elementDeserializer, Function<T,CompoundTag> elementSerializer)
-
Method Summary
Modifier and Type Method Description boolean
accepts(Predicate<T> predicate)
void
fromPacket(PacketByteBuf buf)
void
fromTag(ListTag tag)
T
getByIndex(int index)
int
getIndex(T object)
int
getIndexBits()
int
getPacketSize()
void
toPacket(PacketByteBuf buf)
void
toTag(ListTag tag)
-
Field Details
-
idList
- Mappings:
Namespace Name Mixin selector official a
Lcju;a:Lgh;
intermediary field_12821
Lnet/minecraft/class_2814;field_12821:Lnet/minecraft/class_2361;
named idList
Lnet/minecraft/world/chunk/BiMapPalette;idList:Lnet/minecraft/util/collection/IdList;
-
map
- Mappings:
Namespace Name Mixin selector official b
Lcju;b:Lafk;
intermediary field_12824
Lnet/minecraft/class_2814;field_12824:Lnet/minecraft/class_3513;
named map
Lnet/minecraft/world/chunk/BiMapPalette;map:Lnet/minecraft/util/collection/Int2ObjectBiMap;
-
resizeHandler
- Mappings:
Namespace Name Mixin selector official c
Lcju;c:Lckc;
intermediary field_12825
Lnet/minecraft/class_2814;field_12825:Lnet/minecraft/class_2835;
named resizeHandler
Lnet/minecraft/world/chunk/BiMapPalette;resizeHandler:Lnet/minecraft/world/chunk/PaletteResizeListener;
-
elementDeserializer
- Mappings:
Namespace Name Mixin selector official d
Lcju;d:Ljava/util/function/Function;
intermediary field_12823
Lnet/minecraft/class_2814;field_12823:Ljava/util/function/Function;
named elementDeserializer
Lnet/minecraft/world/chunk/BiMapPalette;elementDeserializer:Ljava/util/function/Function;
-
elementSerializer
- Mappings:
Namespace Name Mixin selector official e
Lcju;e:Ljava/util/function/Function;
intermediary field_12826
Lnet/minecraft/class_2814;field_12826:Ljava/util/function/Function;
named elementSerializer
Lnet/minecraft/world/chunk/BiMapPalette;elementSerializer:Ljava/util/function/Function;
-
indexBits
private final int indexBits- Mappings:
Namespace Name Mixin selector official f
Lcju;f:I
intermediary field_12822
Lnet/minecraft/class_2814;field_12822:I
named indexBits
Lnet/minecraft/world/chunk/BiMapPalette;indexBits:I
-
-
Constructor Details
-
BiMapPalette
public BiMapPalette(IdList<T> idList, int indexBits, PaletteResizeListener<T> resizeHandler, Function<CompoundTag,T> elementDeserializer, Function<T,CompoundTag> elementSerializer)- Mappings:
Namespace Name Mixin selector official <init>
Lcju;<init>(Lgh;ILckc;Ljava/util/function/Function;Ljava/util/function/Function;)V
intermediary <init>
Lnet/minecraft/class_2814;<init>(Lnet/minecraft/class_2361;ILnet/minecraft/class_2835;Ljava/util/function/Function;Ljava/util/function/Function;)V
named <init>
Lnet/minecraft/world/chunk/BiMapPalette;<init>(Lnet/minecraft/util/collection/IdList;ILnet/minecraft/world/chunk/PaletteResizeListener;Ljava/util/function/Function;Ljava/util/function/Function;)V
-
-
Method Details
-
getIndex
-
accepts
- Specified by:
accepts
in interfacePalette<T>
- Mappings:
Namespace Name Mixin selector official a
Lckb;a(Ljava/util/function/Predicate;)Z
intermediary method_19525
Lnet/minecraft/class_2837;method_19525(Ljava/util/function/Predicate;)Z
named accepts
Lnet/minecraft/world/chunk/Palette;accepts(Ljava/util/function/Predicate;)Z
-
getByIndex
- Specified by:
getByIndex
in interfacePalette<T>
- Mappings:
Namespace Name Mixin selector official a
Lckb;a(I)Ljava/lang/Object;
intermediary method_12288
Lnet/minecraft/class_2837;method_12288(I)Ljava/lang/Object;
named getByIndex
Lnet/minecraft/world/chunk/Palette;getByIndex(I)Ljava/lang/Object;
-
fromPacket
- Specified by:
fromPacket
in interfacePalette<T>
- Mappings:
Namespace Name Mixin selector official a
Lckb;a(Lnw;)V
intermediary method_12289
Lnet/minecraft/class_2837;method_12289(Lnet/minecraft/class_2540;)V
named fromPacket
Lnet/minecraft/world/chunk/Palette;fromPacket(Lnet/minecraft/network/PacketByteBuf;)V
-
toPacket
- Specified by:
toPacket
in interfacePalette<T>
- Mappings:
Namespace Name Mixin selector official b
Lckb;b(Lnw;)V
intermediary method_12287
Lnet/minecraft/class_2837;method_12287(Lnet/minecraft/class_2540;)V
named toPacket
Lnet/minecraft/world/chunk/Palette;toPacket(Lnet/minecraft/network/PacketByteBuf;)V
-
getPacketSize
public int getPacketSize()- Specified by:
getPacketSize
in interfacePalette<T>
- Mappings:
Namespace Name Mixin selector official a
Lckb;a()I
intermediary method_12290
Lnet/minecraft/class_2837;method_12290()I
named getPacketSize
Lnet/minecraft/world/chunk/Palette;getPacketSize()I
-
getIndexBits
public int getIndexBits()- Mappings:
Namespace Name Mixin selector official b
Lcju;b()I
intermediary method_12197
Lnet/minecraft/class_2814;method_12197()I
named getIndexBits
Lnet/minecraft/world/chunk/BiMapPalette;getIndexBits()I
-
fromTag
-
toTag
- Mappings:
Namespace Name Mixin selector official b
Lcju;b(Lmw;)V
intermediary method_12196
Lnet/minecraft/class_2814;method_12196(Lnet/minecraft/class_2499;)V
named toTag
Lnet/minecraft/world/chunk/BiMapPalette;toTag(Lnet/minecraft/nbt/ListTag;)V
-