Class IdRegistryImpl<T>

java.lang.Object
dev.engine_room.flywheel.impl.registry.IdRegistryImpl<T>
All Implemented Interfaces:
dev.engine_room.flywheel.api.registry.IdRegistry<T>, Iterable<T>

public class IdRegistryImpl<T> extends Object implements dev.engine_room.flywheel.api.registry.IdRegistry<T>
  • Constructor Details

    • IdRegistryImpl

      public IdRegistryImpl()
  • Method Details

    • register

      public void register(net.minecraft.resources.ResourceLocation id, T object)
      Specified by:
      register in interface dev.engine_room.flywheel.api.registry.IdRegistry<T>
    • registerAndGet

      public <S extends T> S registerAndGet(net.minecraft.resources.ResourceLocation id, S object)
      Specified by:
      registerAndGet in interface dev.engine_room.flywheel.api.registry.IdRegistry<T>
    • get

      @Nullable public T get(net.minecraft.resources.ResourceLocation id)
      Specified by:
      get in interface dev.engine_room.flywheel.api.registry.IdRegistry<T>
    • getId

      @Nullable public @Nullable net.minecraft.resources.ResourceLocation getId(T object)
      Specified by:
      getId in interface dev.engine_room.flywheel.api.registry.IdRegistry<T>
    • getOrThrow

      public T getOrThrow(net.minecraft.resources.ResourceLocation id)
      Specified by:
      getOrThrow in interface dev.engine_room.flywheel.api.registry.IdRegistry<T>
    • getIdOrThrow

      public net.minecraft.resources.ResourceLocation getIdOrThrow(T object)
      Specified by:
      getIdOrThrow in interface dev.engine_room.flywheel.api.registry.IdRegistry<T>
    • getAllIds

      public @UnmodifiableView Set<net.minecraft.resources.ResourceLocation> getAllIds()
      Specified by:
      getAllIds in interface dev.engine_room.flywheel.api.registry.IdRegistry<T>
    • getAll

      public @UnmodifiableView Collection<T> getAll()
      Specified by:
      getAll in interface dev.engine_room.flywheel.api.registry.IdRegistry<T>
    • isFrozen

      public boolean isFrozen()
      Specified by:
      isFrozen in interface dev.engine_room.flywheel.api.registry.IdRegistry<T>
    • iterator

      public Iterator<T> iterator()
      Specified by:
      iterator in interface Iterable<T>
    • freezeAll

      public static void freezeAll()