Class ChatInputManager

java.lang.Object
io.github.lucfr1746.llibrary.chatinput.manager.ChatInputManager

public class ChatInputManager extends Object
The main class that provides the function to prompt for input.
  • Constructor Details

    • ChatInputManager

      public ChatInputManager()
  • Method Details

    • promptInput

      public static CompletableFuture<ChatInputResponse> promptInput(@NotNull @NotNull org.bukkit.plugin.java.JavaPlugin plugin, @NotNull @NotNull UUID uuid, @NotNull @NotNull ChatInput input)
      Prompts the player with the given unique id for input of a given form defined by the ChatInput object.
      Parameters:
      plugin - the plugin
      uuid - the unique id
      input - the input type
      Returns:
      a CompletableFuture that returns the response to the prompt.
    • getCurrentRequest

      @Nullable protected static @Nullable ChatInput getCurrentRequest(@NotNull @NotNull UUID uuid)
    • completeCurrentRequest

      protected static void completeCurrentRequest(@NotNull @NotNull UUID uuid, @NotNull @NotNull ChatInputResponse response)
    • completeAllRequests

      protected static void completeAllRequests(@NotNull @NotNull UUID uuid, @NotNull @NotNull ChatInputResponse response)
    • clearAllRequests

      protected static void clearAllRequests(@NotNull @NotNull UUID uuid)