Interface EndManager


public interface EndManager
API for interacting with BuildMC's End event system.

Provides methods to open or close the End, either with a custom announcement key or using the plugin's default keys.

  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    closeEnd(@Nullable org.bukkit.command.CommandSender sender, @NotNull EndChangeCause cause)
    Requests that the End be closed using BuildMC's default announcement key.
    boolean
    closeEnd(@Nullable org.bukkit.command.CommandSender sender, @NotNull EndChangeCause cause, @NotNull String announcementKey)
    Requests that the End be closed with a custom announcement key.
    @NotNull EndState
    Returns the current state of the End.
    boolean
    openEnd(@Nullable org.bukkit.command.CommandSender sender, @NotNull EndChangeCause cause)
    Requests that the End be opened using BuildMC's default announcement key.
    boolean
    openEnd(@Nullable org.bukkit.command.CommandSender sender, @NotNull EndChangeCause cause, @NotNull String announcementKey)
    Requests that the End be opened with a custom announcement key.
  • Method Details

    • openEnd

      boolean openEnd(@Nullable @Nullable org.bukkit.command.CommandSender sender, @NotNull @NotNull EndChangeCause cause, @NotNull @NotNull String announcementKey)
      Requests that the End be opened with a custom announcement key.
      Parameters:
      sender - the CommandSender triggering the open; may be null
      cause - the reason the End is opening
      announcementKey - the announcement message key
      Returns:
      true if the operation was successful (not cancelled)
    • closeEnd

      boolean closeEnd(@Nullable @Nullable org.bukkit.command.CommandSender sender, @NotNull @NotNull EndChangeCause cause, @NotNull @NotNull String announcementKey)
      Requests that the End be closed with a custom announcement key.
      Parameters:
      sender - the CommandSender triggering the close; may be null
      cause - the reason the End is closing
      announcementKey - the announcement message key
      Returns:
      true if the operation was successful (not cancelled)
    • openEnd

      boolean openEnd(@Nullable @Nullable org.bukkit.command.CommandSender sender, @NotNull @NotNull EndChangeCause cause)
      Requests that the End be opened using BuildMC's default announcement key.
      Parameters:
      sender - the CommandSender triggering the open; may be null
      cause - the reason the End is opening
      Returns:
      true if the operation was successful (not cancelled)
    • closeEnd

      boolean closeEnd(@Nullable @Nullable org.bukkit.command.CommandSender sender, @NotNull @NotNull EndChangeCause cause)
      Requests that the End be closed using BuildMC's default announcement key.
      Parameters:
      sender - the CommandSender triggering the close; may be null
      cause - the reason the End is closing
      Returns:
      true if the operation was successful (not cancelled)
    • getCurrentState

      @NotNull @NotNull EndState getCurrentState()
      Returns the current state of the End.
      Returns:
      the current EndState, never null