Package io.papermc.paper.registry.event
Interface RegistryEventProvider<T,B extends RegistryBuilder<T>> 
- Type Parameters:
- T- registry entry type
- B- registry entry builder type
Provider for registry events for a specific registry.
 
Supported events are:
- RegistryEntryAddEvent(via- entryAdd())
- RegistryComposeEvent(via- compose())
- 
Method SummaryModifier and TypeMethodDescriptioncompose()Gets the event type forRegistryComposeEventwhich is fired after a registry is loaded of expected elements.entryAdd()Gets the event type forRegistryEntryAddEventwhich is fired just before an object is added to a registry.freeze()Deprecated, for removal: This API element is subject to removal in a future version.Gets the registry key associated with this event type provider.
- 
Method Details- 
entryAddRegistryEntryAddEventType<T,B> entryAdd()Gets the event type forRegistryEntryAddEventwhich is fired just before an object is added to a registry.Can be used in LifecycleEventManager.registerEventHandler(LifecycleEventType, LifecycleEventHandler)to register a handler forRegistryEntryAddEvent.- Returns:
- the registry entry add event type
 
- 
freeze@ScheduledForRemoval(inVersion="1.21.7 or 1.22, whichever comes first") @Deprecated(since="1.21.6", forRemoval=true) default LifecycleEventType.Prioritizable<BootstrapContext,RegistryFreezeEvent<T, freeze()B>> Deprecated, for removal: This API element is subject to removal in a future version.usecompose()instead.Gets the event type forRegistryFreezeEventwhich is fired just before a registry is frozen. It allows for the registration of new objects.Can be used in LifecycleEventManager.registerEventHandler(LifecycleEventType, LifecycleEventHandler)to register a handler forRegistryFreezeEvent.- Returns:
- the registry freeze event type
 
- 
composeGets the event type forRegistryComposeEventwhich is fired after a registry is loaded of expected elements. It allows for the registration of new objects.Can be used in LifecycleEventManager.registerEventHandler(LifecycleEventType, LifecycleEventHandler)to register a handler forRegistryComposeEvent.- Returns:
- the registry freeze event type
 
- 
registryKeyRegistryKey<T> registryKey()Gets the registry key associated with this event type provider.- Returns:
- the registry key
 
 
- 
compose()instead.