Interface GenericServerListEvent
- All Known Implementing Classes:
PreServerListSetEvent,PreServerListSetEvent
@NullMarked
public interface GenericServerListEvent
Interface used for the platform-specific PreServerListSetEvent instances.
This allows the plugin to pull common info such as the
This allows the plugin to pull common info such as the
ProfileEntry used or if the Event has been canceled by
another plugin.-
Method Summary
Modifier and TypeMethodDescriptiongetEntry()Gets theProfileEntrycurrently set for this Event.booleanReturns whether this Event has been canceled or not.voidsetCancelled(boolean cancelled) Sets the Event's canceled state.voidsetEntry(ProfileEntry entry) Sets theProfileEntryto use for this Event.
-
Method Details
-
getEntry
ProfileEntry getEntry()Gets theProfileEntrycurrently set for this Event.- Returns:
- The currently set
ProfileEntry
-
isCancelled
boolean isCancelled()Returns whether this Event has been canceled or not.- Returns:
- Whether the event has been canceled or not.
-
setEntry
- Parameters:
entry- The newProfileEntryto use. May not benull,- Throws:
IllegalArgumentException- Should the provided ProfileEntry benull.
-
setCancelled
void setCancelled(boolean cancelled) Sets the Event's canceled state.- Parameters:
cancelled- Boolean to set the Event's canceled State.
-