Class ChatInputManager
java.lang.Object
io.github.lucfr1746.llibrary.chatinput.manager.ChatInputManager
The main class that provides the function to prompt for input.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected static voidclearAllRequests(@NotNull UUID uuid) protected static voidcompleteAllRequests(@NotNull UUID uuid, @NotNull ChatInputResponse response) protected static voidcompleteCurrentRequest(@NotNull UUID uuid, @NotNull ChatInputResponse response) protected static @Nullable ChatInputgetCurrentRequest(@NotNull UUID uuid) static CompletableFuture<ChatInputResponse> promptInput(@NotNull org.bukkit.plugin.java.JavaPlugin plugin, @NotNull UUID uuid, @NotNull ChatInput input) Prompts the player with the given unique id for input of a given form defined by the ChatInput object.
-
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 pluginuuid- the unique idinput- the input type- Returns:
- a CompletableFuture that returns the response to the prompt.
-
getCurrentRequest
-
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
-