Package net.minecraft.registry
Class RegistryCodecs
java.lang.Object
net.minecraft.registry.RegistryCodecs
A utility class for serialization of registries using codecs.
- Mappings:
Namespace Name named net/minecraft/registry/RegistryCodecs
intermediary net/minecraft/class_6895
official kf
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic <E> com.mojang.serialization.Codec
<RegistryEntryList<E>> entryList
(RegistryKey<? extends Registry<E>> registryRef) static <E> com.mojang.serialization.Codec
<RegistryEntryList<E>> entryList
(RegistryKey<? extends Registry<E>> registryRef, boolean alwaysSerializeAsList) static <E> com.mojang.serialization.Codec
<RegistryEntryList<E>> entryList
(RegistryKey<? extends Registry<E>> registryRef, com.mojang.serialization.Codec<E> elementCodec) static <E> com.mojang.serialization.Codec
<RegistryEntryList<E>> entryList
(RegistryKey<? extends Registry<E>> registryRef, com.mojang.serialization.Codec<E> elementCodec, boolean alwaysSerializeAsList)
-
Constructor Details
-
RegistryCodecs
public RegistryCodecs()
-
-
Method Details
-
entryList
public static <E> com.mojang.serialization.Codec<RegistryEntryList<E>> entryList(RegistryKey<? extends Registry<E>> registryRef, com.mojang.serialization.Codec<E> elementCodec) - Mappings:
Namespace Name Mixin selector named entryList
Lnet/minecraft/registry/RegistryCodecs;entryList(Lnet/minecraft/registry/RegistryKey;Lcom/mojang/serialization/Codec;)Lcom/mojang/serialization/Codec;
intermediary method_40341
Lnet/minecraft/class_6895;method_40341(Lnet/minecraft/class_5321;Lcom/mojang/serialization/Codec;)Lcom/mojang/serialization/Codec;
official a
Lkf;a(Laly;Lcom/mojang/serialization/Codec;)Lcom/mojang/serialization/Codec;
-
entryList
public static <E> com.mojang.serialization.Codec<RegistryEntryList<E>> entryList(RegistryKey<? extends Registry<E>> registryRef, com.mojang.serialization.Codec<E> elementCodec, boolean alwaysSerializeAsList) - Parameters:
alwaysSerializeAsList
- whether to always serialize the list as a list instead of serializing as one entry if the length is0
- Mappings:
Namespace Name Mixin selector named entryList
Lnet/minecraft/registry/RegistryCodecs;entryList(Lnet/minecraft/registry/RegistryKey;Lcom/mojang/serialization/Codec;Z)Lcom/mojang/serialization/Codec;
intermediary method_40343
Lnet/minecraft/class_6895;method_40343(Lnet/minecraft/class_5321;Lcom/mojang/serialization/Codec;Z)Lcom/mojang/serialization/Codec;
official a
Lkf;a(Laly;Lcom/mojang/serialization/Codec;Z)Lcom/mojang/serialization/Codec;
-
entryList
public static <E> com.mojang.serialization.Codec<RegistryEntryList<E>> entryList(RegistryKey<? extends Registry<E>> registryRef) - Mappings:
Namespace Name Mixin selector named entryList
Lnet/minecraft/registry/RegistryCodecs;entryList(Lnet/minecraft/registry/RegistryKey;)Lcom/mojang/serialization/Codec;
intermediary method_40340
Lnet/minecraft/class_6895;method_40340(Lnet/minecraft/class_5321;)Lcom/mojang/serialization/Codec;
official a
Lkf;a(Laly;)Lcom/mojang/serialization/Codec;
-
entryList
public static <E> com.mojang.serialization.Codec<RegistryEntryList<E>> entryList(RegistryKey<? extends Registry<E>> registryRef, boolean alwaysSerializeAsList) - Parameters:
alwaysSerializeAsList
- whether to always serialize the list as a list instead of serializing as one entry if the length is0
- Mappings:
Namespace Name Mixin selector named entryList
Lnet/minecraft/registry/RegistryCodecs;entryList(Lnet/minecraft/registry/RegistryKey;Z)Lcom/mojang/serialization/Codec;
intermediary method_40349
Lnet/minecraft/class_6895;method_40349(Lnet/minecraft/class_5321;Z)Lcom/mojang/serialization/Codec;
official a
Lkf;a(Laly;Z)Lcom/mojang/serialization/Codec;
-