Class RegistriesImpl.RegistryImpl<T>

java.lang.Object
me.shedaniel.architectury.registry.fabric.RegistriesImpl.RegistryImpl<T>
All Implemented Interfaces:
Iterable<T>, me.shedaniel.architectury.registry.Registry<T>
Enclosing class:
RegistriesImpl

public static class RegistriesImpl.RegistryImpl<T> extends Object implements me.shedaniel.architectury.registry.Registry<T>
  • Constructor Summary

    Constructors
    Constructor
    Description
    RegistryImpl(net.minecraft.core.Registry<T> delegate)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    byRawId(int rawId)
     
    boolean
    contains(net.minecraft.resources.ResourceLocation id)
     
    boolean
     
    @NotNull me.shedaniel.architectury.registry.RegistrySupplier<T>
    delegateSupplied(net.minecraft.resources.ResourceLocation id)
     
    Set<Map.Entry<net.minecraft.resources.ResourceKey<T>,T>>
     
    get(net.minecraft.resources.ResourceLocation id)
     
    @Nullable net.minecraft.resources.ResourceLocation
    getId(T obj)
     
    Set<net.minecraft.resources.ResourceLocation>
     
    Optional<net.minecraft.resources.ResourceKey<T>>
    getKey(T obj)
     
    int
    getRawId(T obj)
     
    @NotNull Iterator<T>
     
    net.minecraft.resources.ResourceKey<? extends net.minecraft.core.Registry<T>>
    key()
     
    <E extends T>
    @NotNull me.shedaniel.architectury.registry.RegistrySupplier<E>
    registerSupplied(net.minecraft.resources.ResourceLocation id, Supplier<E> supplier)
     

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

    Methods inherited from interface java.lang.Iterable

    forEach, spliterator

    Methods inherited from interface me.shedaniel.architectury.registry.Registry

    delegate, register
  • Constructor Details

    • RegistryImpl

      public RegistryImpl(net.minecraft.core.Registry<T> delegate)
  • Method Details

    • delegateSupplied

      @NotNull public @NotNull me.shedaniel.architectury.registry.RegistrySupplier<T> delegateSupplied(net.minecraft.resources.ResourceLocation id)
      Specified by:
      delegateSupplied in interface me.shedaniel.architectury.registry.Registry<T>
    • registerSupplied

      @NotNull public <E extends T> @NotNull me.shedaniel.architectury.registry.RegistrySupplier<E> registerSupplied(net.minecraft.resources.ResourceLocation id, Supplier<E> supplier)
      Specified by:
      registerSupplied in interface me.shedaniel.architectury.registry.Registry<T>
    • getId

      @Nullable public @Nullable net.minecraft.resources.ResourceLocation getId(T obj)
      Specified by:
      getId in interface me.shedaniel.architectury.registry.Registry<T>
    • getRawId

      public int getRawId(T obj)
      Specified by:
      getRawId in interface me.shedaniel.architectury.registry.Registry<T>
    • getKey

      public Optional<net.minecraft.resources.ResourceKey<T>> getKey(T obj)
      Specified by:
      getKey in interface me.shedaniel.architectury.registry.Registry<T>
    • get

      @Nullable public T get(net.minecraft.resources.ResourceLocation id)
      Specified by:
      get in interface me.shedaniel.architectury.registry.Registry<T>
    • byRawId

      public T byRawId(int rawId)
      Specified by:
      byRawId in interface me.shedaniel.architectury.registry.Registry<T>
    • contains

      public boolean contains(net.minecraft.resources.ResourceLocation id)
      Specified by:
      contains in interface me.shedaniel.architectury.registry.Registry<T>
    • containsValue

      public boolean containsValue(T obj)
      Specified by:
      containsValue in interface me.shedaniel.architectury.registry.Registry<T>
    • getIds

      public Set<net.minecraft.resources.ResourceLocation> getIds()
      Specified by:
      getIds in interface me.shedaniel.architectury.registry.Registry<T>
    • entrySet

      public Set<Map.Entry<net.minecraft.resources.ResourceKey<T>,T>> entrySet()
      Specified by:
      entrySet in interface me.shedaniel.architectury.registry.Registry<T>
    • key

      public net.minecraft.resources.ResourceKey<? extends net.minecraft.core.Registry<T>> key()
      Specified by:
      key in interface me.shedaniel.architectury.registry.Registry<T>
    • iterator

      @NotNull public @NotNull Iterator<T> iterator()
      Specified by:
      iterator in interface Iterable<T>