Package net.minecraft.core
Interface HolderGetter.Provider
- All Known Subinterfaces:
CommandBuildContext,HolderLookup.Provider,RegistryAccess,RegistryAccess.Frozen
- All Known Implementing Classes:
PlaceholderLookupProvider,RegistryAccess.ImmutableRegistryAccess
- Enclosing interface:
HolderGetter<T>
public static interface HolderGetter.Provider
-
Method Summary
Modifier and TypeMethodDescriptiondefault <T> Optional<Holder.Reference<T>> get(ResourceKey<T> key) default <T> Holder.Reference<T> getOrThrow(ResourceKey<T> key) <T> Optional<? extends HolderGetter<T>> lookup(ResourceKey<? extends Registry<? extends T>> registryKey) default <T> HolderGetter<T> lookupOrThrow(ResourceKey<? extends Registry<? extends T>> registryKey)
-
Method Details
-
lookup
<T> Optional<? extends HolderGetter<T>> lookup(ResourceKey<? extends Registry<? extends T>> registryKey) -
lookupOrThrow
-
get
-
getOrThrow
-