Interface IHolderExtension<T>
- All Superinterfaces:
IWithData<T>
- All Known Subinterfaces:
Holder<T>
- All Known Implementing Classes:
DeferredBlock,DeferredBlockBuilder,DeferredEntityTypeBuilder,DeferredHolder,DeferredItem,DeferredItemBuilder,Holder.Direct,Holder.Reference,RegistrySetBuilder.LazyHolder
Extension for
Holder-
Method Summary
Modifier and TypeMethodDescriptionReturns the holder that this holder wraps.default HolderLookup.RegistryLookup<T> Attempts to resolve the underlyingHolderLookup.RegistryLookupfrom aHolder.
-
Method Details
-
getDelegate
Returns the holder that this holder wraps. Used byRegistry.safeCastToReference(net.minecraft.core.Holder<T>)to resolve the underlyingHolder.Referencefor delegating holders.- Returns:
- the holder that this holder wraps
-
unwrapLookup
Attempts to resolve the underlyingHolderLookup.RegistryLookupfrom aHolder.This will only succeed if the underlying holder is a
Holder.Reference.
-