Interface IForgeRegistry<V extends IForgeRegistryEntry<V>>

Type Parameters:
V - The top level type for the registry
All Superinterfaces:
All Known Subinterfaces:
IForgeRegistryInternal<V>, IForgeRegistryModifiable<V>
All Known Implementing Classes:

public interface IForgeRegistry<V extends IForgeRegistryEntry<V>> extends Iterable<V>
Main interface for the registry system. Use this to query the registry system.
  • Method Details

    • getRegistryName

      ResourceLocation getRegistryName()
    • getRegistrySuperType

      Class<V> getRegistrySuperType()
    • register

      void register(V value)
    • registerAll

      void registerAll(V... values)
    • containsKey

      boolean containsKey(ResourceLocation key)
    • containsValue

      boolean containsValue(V value)
    • isEmpty

      boolean isEmpty()
    • getValue

      @Nullable V getValue(ResourceLocation key)
    • getKey

      @Nullable ResourceLocation getKey(V value)
    • getDefaultKey

      @Nullable ResourceLocation getDefaultKey()
    • getKeys

      @Nonnull Set<ResourceLocation> getKeys()
    • getValues

      @Nonnull Collection<V> getValues()
    • getEntries

      @Nonnull Set<Map.Entry<RegistryKey<V>,V>> getEntries()
    • getSlaveMap

      <T> T getSlaveMap(ResourceLocation slaveMapName, Class<T> type)
      Retrieve the slave map of type T from the registry. Slave maps are maps which are dependent on registry content in some way.
      Type Parameters:
      T - Type to return
      slaveMapName - The name of the slavemap
      type - The type
      The slavemap if present