Interface ConfirmationDialog<I,BB extends DialogBodyBuilder<I>,IB extends DialogInputBuilder,D extends Dialog<I,BB,IB,?>,AB extends DialogActionBuilder<D,AB>,T extends ConfirmationDialog<I,BB,IB,D,AB,T>>

Type Parameters:
I - the type of the item for the item body
BB - the type of the dialog body builder
IB - the type of the dialog input builder
D - the type of the base dialog
AB - the type of the dialog action builder
T - the type of the confirmation dialog itself, for method chaining
All Superinterfaces:
Dialog<I,BB,IB,T>
All Known Implementing Classes:
PaperConfirmationDialog, PEConfirmationDialog, SpigotConfirmationDialog

public interface ConfirmationDialog<I,BB extends DialogBodyBuilder<I>,IB extends DialogInputBuilder,D extends Dialog<I,BB,IB,?>,AB extends DialogActionBuilder<D,AB>,T extends ConfirmationDialog<I,BB,IB,D,AB,T>> extends Dialog<I,BB,IB,T>
Interface representing a confirmation dialog.
  • Method Details

    • yesAction

      T yesAction(Consumer<AB> action)
      Set the action for the "yes" button in the confirmation dialog
      Parameters:
      action - the action to be performed when the "yes" button is clicked
      Returns:
      the confirmation dialog itself for method chaining
    • noAction

      T noAction(Consumer<AB> action)
      Set the action for the "no" button in the confirmation dialog
      Parameters:
      action - the action to be performed when the "no" button is clicked
      Returns:
      the confirmation dialog itself for method chaining
    • hasYesAction

      boolean hasYesAction()
      Check if the confirmation dialog has a "yes" action defined
      Returns:
      true if a "yes" action is defined, false otherwise
    • hasNoAction

      boolean hasNoAction()
      Check if the confirmation dialog has a "no" action defined
      Returns:
      true if a "no" action is defined, false otherwise