Interface RegistrationProvider.Factory
- All Known Implementing Classes:
NeoForgeRegistrationFactory
- Enclosing interface:
RegistrationProvider<T>
public static interface RegistrationProvider.Factory
Factory class for
This class is loaded using
registration providers. This class is loaded using
Service Loaders, and only one
should exist per mod loader.-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final RegistrationProvider.FactoryThe singleton instance of theRegistrationProvider.Factory. -
Method Summary
Modifier and TypeMethodDescriptiondefault <T> RegistrationProvider<T> Creates aRegistrationProvider.<T> RegistrationProvider<T> create(net.minecraft.resources.ResourceKey<? extends net.minecraft.core.Registry<T>> resourceKey, String modId) Creates aRegistrationProvider.
-
Field Details
-
INSTANCE
The singleton instance of theRegistrationProvider.Factory. This is different on each loader.
-
-
Method Details
-
create
<T> RegistrationProvider<T> create(net.minecraft.resources.ResourceKey<? extends net.minecraft.core.Registry<T>> resourceKey, String modId) Creates aRegistrationProvider.- Type Parameters:
T- the type of the provider- Parameters:
resourceKey- theResourceKeyof the registry to create this provider formodId- the mod id for which the provider will register objects- Returns:
- the provider
-
create
Creates aRegistrationProvider.- Type Parameters:
T- the type of the provider- Parameters:
registry- theRegistryto create this provider formodId- the mod id for which the provider will register objects- Returns:
- the provider
-