Package net.okocraft.box.api.feature
Interface BoxFeature
- All Known Implementing Classes:
AbstractBoxFeature
,AutoStoreFeature
,StickFeature
public interface BoxFeature
An interface that adds a box feature.
-
Method Summary
Modifier and TypeMethodDescriptionvoid
disable
(FeatureContext.Disabling context) Disables thisBoxFeature
.void
enable
(FeatureContext.Enabling context) Enables thisBoxFeature
.default @NotNull @Unmodifiable Set
<Class<? extends BoxFeature>> Gets classes of the dependentBoxFeature
.@NotNull String
getName()
Gets the name of this feature.
-
Method Details
-
getName
Gets the name of this feature.- Returns:
- the name of this feature
-
enable
Enables thisBoxFeature
.- Parameters:
context
- theFeatureContext.Enabling
context- Throws:
Throwable
- if an exception occurred while enabling
-
disable
Disables thisBoxFeature
.- Parameters:
context
- theFeatureContext.Disabling
context- Throws:
Throwable
- if an exception occurred while disabling
-
getDependencies
Gets classes of the dependentBoxFeature
.- Returns:
- classes of the dependent
BoxFeature
-