Class SimpleJsonResourceReloadListener
java.lang.Object
net.neoforged.neoforge.resource.ContextAwareReloadListener
net.minecraft.server.packs.resources.SimplePreparableReloadListener<Map<ResourceLocation,com.google.gson.JsonElement>>
net.minecraft.server.packs.resources.SimpleJsonResourceReloadListener
- All Implemented Interfaces:
PreparableReloadListener
- Direct Known Subclasses:
LootModifierManager
,RecipeManager
,ServerAdvancementManager
public abstract class SimpleJsonResourceReloadListener
extends SimplePreparableReloadListener<Map<ResourceLocation,com.google.gson.JsonElement>>
-
Nested Class Summary
Nested classes/interfaces inherited from interface net.minecraft.server.packs.resources.PreparableReloadListener
PreparableReloadListener.PreparationBarrier
-
Field Summary
Modifier and TypeFieldDescriptionprivate final String
private final com.google.gson.Gson
private static final org.slf4j.Logger
Fields inherited from class net.neoforged.neoforge.resource.ContextAwareReloadListener
conditionContext, registryAccess
-
Constructor Summary
ConstructorDescriptionSimpleJsonResourceReloadListener
(com.google.gson.Gson p_10768_, String p_10769_) -
Method Summary
Modifier and TypeMethodDescriptionprotected ResourceLocation
protected Map<ResourceLocation,
com.google.gson.JsonElement> prepare
(ResourceManager p_10771_, ProfilerFiller p_10772_) static void
scanDirectory
(ResourceManager p_279308_, String p_279131_, com.google.gson.Gson p_279261_, Map<ResourceLocation, com.google.gson.JsonElement> p_279404_) Methods inherited from class net.minecraft.server.packs.resources.SimplePreparableReloadListener
apply, reload
Methods inherited from class net.neoforged.neoforge.resource.ContextAwareReloadListener
injectContext
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface net.minecraft.server.packs.resources.PreparableReloadListener
getName
-
Field Details
-
LOGGER
private static final org.slf4j.Logger LOGGER -
gson
private final com.google.gson.Gson gson -
directory
-
-
Constructor Details
-
SimpleJsonResourceReloadListener
-
-
Method Details
-
prepare
protected Map<ResourceLocation,com.google.gson.JsonElement> prepare(ResourceManager p_10771_, ProfilerFiller p_10772_) - Specified by:
prepare
in classSimplePreparableReloadListener<Map<ResourceLocation,
com.google.gson.JsonElement>>
-
scanDirectory
public static void scanDirectory(ResourceManager p_279308_, String p_279131_, com.google.gson.Gson p_279261_, Map<ResourceLocation, com.google.gson.JsonElement> p_279404_) -
getPreparedPath
-