java.lang.Object
io.github.projectunified.unidialog.packetevents.opener.PEDialogOpener
All Implemented Interfaces:
DialogOpener

public class PEDialogOpener extends Object implements DialogOpener
  • Constructor Summary

    Constructors
    Constructor
    Description
    PEDialogOpener(com.github.retrooper.packetevents.protocol.dialog.Dialog dialog, Function<UUID,@Nullable Object> playerFunction)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    com.github.retrooper.packetevents.protocol.dialog.Dialog
    Get the dialog associated with this opener
    void
    open(com.github.retrooper.packetevents.protocol.player.User user)
    Open the dialog for a user, automatically determining if it is a configuration dialog based on the user's connection state.
    void
    open(com.github.retrooper.packetevents.protocol.player.User user, boolean configuration)
    Open the dialog for a user, optionally specifying if it is a configuration dialog.
    boolean
    open(UUID uuid)
    Open the dialog for the given player UUID

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • PEDialogOpener

      public PEDialogOpener(com.github.retrooper.packetevents.protocol.dialog.Dialog dialog, Function<UUID,@Nullable Object> playerFunction)
  • Method Details

    • dialog

      public com.github.retrooper.packetevents.protocol.dialog.Dialog dialog()
      Get the dialog associated with this opener
      Returns:
      the dialog
    • open

      public void open(com.github.retrooper.packetevents.protocol.player.User user, boolean configuration)
      Open the dialog for a user, optionally specifying if it is a configuration dialog.
      Parameters:
      user - the user to open the dialog for
      configuration - if true, opens as a configuration dialog; if false, opens as a play dialog
    • open

      public void open(com.github.retrooper.packetevents.protocol.player.User user)
      Open the dialog for a user, automatically determining if it is a configuration dialog based on the user's connection state.
      Parameters:
      user - the user to open the dialog for
    • open

      public boolean open(UUID uuid)
      Description copied from interface: DialogOpener
      Open the dialog for the given player UUID
      Specified by:
      open in interface DialogOpener
      Parameters:
      uuid - the UUID of the player to open the dialog for
      Returns:
      true if the dialog was opened successfully, false otherwise