Package me.croabeast.common
Interface Registrable
- All Known Subinterfaces:
CustomListener
public interface Registrable
Represents a component that can be registered and unregistered within a plugin.
This interface provides methods to check if the component is registered, to register the component, and to unregister the component.
-
Method Summary
Modifier and TypeMethodDescriptionbooleanChecks if the component is currently registered.booleanregister()Registers the component.booleanUnregisters the component.
-
Method Details
-
isRegistered
boolean isRegistered()Checks if the component is currently registered.This method should return
trueif the component is active and functioning within the plugin.- Returns:
trueif the component is enabled,falseotherwise.
-
register
boolean register()Registers the component.The registration process may involve adding the component to some registry, initializing necessary components, or performing any setup required for the component to function properly.
- Returns:
trueif the registration was successful,falseotherwise.
-
unregister
boolean unregister()Unregisters the component.The unregistration process may involve removing the component from some registry, cleaning up resources, or performing any tear down required for the component to be properly disabled.
- Returns:
trueif the unregistration was successful,falseotherwise.
-