Package net.minecraft.util.dynamic
Class RegistryOps.EntryLoader.Impl
java.lang.Object
net.minecraft.util.dynamic.RegistryOps.EntryLoader.Impl
- All Implemented Interfaces:
RegistryOps.EntryLoader
- Enclosing interface:
- RegistryOps.EntryLoader
public static final class RegistryOps.EntryLoader.Impl extends Object implements RegistryOps.EntryLoader
-
Nested Class Summary
Nested classes/interfaces inherited from interface net.minecraft.util.dynamic.RegistryOps.EntryLoader
RegistryOps.EntryLoader.Impl
-
Field Summary
Fields Modifier and Type Field Description private Map<RegistryKey<?>,com.mojang.serialization.Lifecycle>
entryToLifecycle
private Object2IntMap<RegistryKey<?>>
entryToRawId
private Map<RegistryKey<?>,JsonElement>
values
-
Constructor Summary
Constructors Constructor Description Impl()
-
Method Summary
Modifier and Type Method Description <E> void
add(DynamicRegistryManager.Impl impl, RegistryKey<E> registryKey, com.mojang.serialization.Encoder<E> encoder, int rawId, E e, com.mojang.serialization.Lifecycle lifecycle)
Collection<Identifier>
getKnownEntryPaths(RegistryKey<? extends Registry<?>> registryKey)
<E> com.mojang.serialization.DataResult<com.mojang.datafixers.util.Pair<E,OptionalInt>>
load(com.mojang.serialization.DynamicOps<JsonElement> dynamicOps, RegistryKey<? extends Registry<E>> registryId, RegistryKey<E> entryId, com.mojang.serialization.Decoder<E> decoder)
-
Field Details
-
values
-
entryToRawId
-
entryToLifecycle
-
-
Constructor Details
-
Impl
public Impl()
-
-
Method Details
-
add
public <E> void add(DynamicRegistryManager.Impl impl, RegistryKey<E> registryKey, com.mojang.serialization.Encoder<E> encoder, int rawId, E e, com.mojang.serialization.Lifecycle lifecycle) -
getKnownEntryPaths
- Specified by:
getKnownEntryPaths
in interfaceRegistryOps.EntryLoader
- Returns:
- A collection of file Identifiers of all known entries of the given registry. Note that these are file Identifiers for use in a resource manager, not the logical names of the entries.
-
load
public <E> com.mojang.serialization.DataResult<com.mojang.datafixers.util.Pair<E,OptionalInt>> load(com.mojang.serialization.DynamicOps<JsonElement> dynamicOps, RegistryKey<? extends Registry<E>> registryId, RegistryKey<E> entryId, com.mojang.serialization.Decoder<E> decoder)- Specified by:
load
in interfaceRegistryOps.EntryLoader
-