Class EventRegistry
java.lang.Object
dev.despical.whackme.api.EventRegistry
Provides read-only discovery helpers for the events exposed by Whack Me.
This class deliberately contains no mutable registration state: the event
catalog is defined by EventType, while actual listener registration
continues to use Bukkit's standard plugin manager.
API Note: Use this registry when building generic integrations such as event browsers or profilers. Normal listeners should register against the concrete event classes.
-
Method Summary
Modifier and TypeMethodDescriptionstatic Class<? extends org.bukkit.event.Event> getEventClass(EventType type) Resolves the concrete Bukkit event class represented by a logical type.Returns a fresh set containing every event type exposed by the API.static booleanTests whether an event instance belongs to the supplied logical type.
-
Method Details
-
getEventClass
-
matches
Tests whether an event instance belongs to the supplied logical type. Subclasses are accepted throughClass.isInstance(Object).- Parameters:
type- expected logical event typeevent- event instance to test- Returns:
truewhen the event is compatible with the mapped class
-
getRegisteredTypes
-