Class ResourceReloader.Store

java.lang.Object
net.minecraft.resource.ResourceReloader.Store
Enclosing interface:
ResourceReloader

public static final class ResourceReloader.Store extends Object
A data store that can be used for sharing state between resource reloaders. Values can be inserted during prepareSharedState and retrieved during reload.
Mappings:
Namespace Name
named net/minecraft/resource/ResourceReloader$Store
intermediary net/minecraft/class_3302$class_11558
official baj$b
  • Field Details

    • resourceManager

      private final ResourceManager resourceManager
      Mappings:
      Namespace Name Mixin selector
      named resourceManager Lnet/minecraft/resource/ResourceReloader$Store;resourceManager:Lnet/minecraft/resource/ResourceManager;
      intermediary field_61161 Lnet/minecraft/class_3302$class_11558;field_61161:Lnet/minecraft/class_3300;
      official a Lbaj$b;a:Lbap;
    • store

      private final Map<ResourceReloader.Key<?>,Object> store
      Mappings:
      Namespace Name Mixin selector
      named store Lnet/minecraft/resource/ResourceReloader$Store;store:Ljava/util/Map;
      intermediary field_61162 Lnet/minecraft/class_3302$class_11558;field_61162:Ljava/util/Map;
      official b Lbaj$b;b:Ljava/util/Map;
  • Constructor Details

    • Store

      public Store(ResourceManager resourceManager)
      Mappings:
      Namespace Name Mixin selector
      named <init> Lnet/minecraft/resource/ResourceReloader$Store;<init>(Lnet/minecraft/resource/ResourceManager;)V
      intermediary <init> Lnet/minecraft/class_3302$class_11558;<init>(Lnet/minecraft/class_3300;)V
      official <init> Lbaj$b;<init>(Lbap;)V
  • Method Details

    • getResourceManager

      public ResourceManager getResourceManager()
      Mappings:
      Namespace Name Mixin selector
      named getResourceManager Lnet/minecraft/resource/ResourceReloader$Store;getResourceManager()Lnet/minecraft/resource/ResourceManager;
      intermediary method_72361 Lnet/minecraft/class_3302$class_11558;method_72361()Lnet/minecraft/class_3300;
      official a Lbaj$b;a()Lbap;
    • put

      public <T> void put(ResourceReloader.Key<T> key, T value)
      Inserts a value associated with the given key into the data store.
      Mappings:
      Namespace Name Mixin selector
      named put Lnet/minecraft/resource/ResourceReloader$Store;put(Lnet/minecraft/resource/ResourceReloader$Key;Ljava/lang/Object;)V
      intermediary method_72363 Lnet/minecraft/class_3302$class_11558;method_72363(Lnet/minecraft/class_3302$class_11559;Ljava/lang/Object;)V
      official a Lbaj$b;a(Lbaj$c;Ljava/lang/Object;)V
    • getOrThrow

      public <T> T getOrThrow(ResourceReloader.Key<T> key)
      Returns the value associated with the given key.. This is safe to call during reload if any resource reloader has previously inserted a value with the same key object during prepareSharedState.
      Returns:
      the value associated with the given key
      Mappings:
      Namespace Name Mixin selector
      named getOrThrow Lnet/minecraft/resource/ResourceReloader$Store;getOrThrow(Lnet/minecraft/resource/ResourceReloader$Key;)Ljava/lang/Object;
      intermediary method_72362 Lnet/minecraft/class_3302$class_11558;method_72362(Lnet/minecraft/class_3302$class_11559;)Ljava/lang/Object;
      official a Lbaj$b;a(Lbaj$c;)Ljava/lang/Object;