public abstract class PlayerNamePrompt extends ValidatingPrompt
END_OF_CONVERSATION
Constructor and Description |
---|
PlayerNamePrompt(@NotNull Plugin plugin) |
Modifier and Type | Method and Description |
---|---|
protected abstract @Nullable Prompt |
acceptValidatedInput(@NotNull ConversationContext context,
@NotNull Player input)
Override this method to perform some action with the user's player name
response.
|
protected @Nullable Prompt |
acceptValidatedInput(@NotNull ConversationContext context,
@NotNull String input)
Override this method to accept and processes the validated input from
the user.
|
protected boolean |
isInputValid(@NotNull ConversationContext context,
@NotNull String input)
Override this method to check the validity of the player's input.
|
acceptInput, blocksForInput, getFailedValidationText
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getPromptText
protected boolean isInputValid(@NotNull @NotNull ConversationContext context, @NotNull @NotNull String input)
ValidatingPrompt
isInputValid
in class ValidatingPrompt
context
- Context information about the conversation.input
- The player's raw console input.@Nullable protected @Nullable Prompt acceptValidatedInput(@NotNull @NotNull ConversationContext context, @NotNull @NotNull String input)
ValidatingPrompt
acceptValidatedInput
in class ValidatingPrompt
context
- Context information about the conversation.input
- The validated input text from the user.@Nullable protected abstract @Nullable Prompt acceptValidatedInput(@NotNull @NotNull ConversationContext context, @NotNull @NotNull Player input)
context
- Context information about the conversation.input
- The user's player name response.Prompt
in the prompt graph.Copyright © 2021. All rights reserved.