Class ConversationRequester
java.lang.Object
de.eldoria.eldoutilities.conversation.ConversationRequester
- All Implemented Interfaces:
Cloneable
,EventListener
,ConversationAbandonedListener
,ConversationCanceller
public class ConversationRequester
extends Object
implements ConversationAbandonedListener, ConversationCanceller
Class to handle Conversations.
-
Method Summary
Modifier and TypeMethodDescriptionboolean
cancelBasedOnInput
(@NotNull ConversationContext context, @NotNull String input) clone()
void
conversationAbandoned
(@NotNull ConversationAbandonedEvent abandonedEvent) void
requestInput
(Player player, String text, Predicate<String> validation, int timeout, Consumer<String> callback) void
setConversation
(@NotNull Conversation conversation) static ConversationRequester
-
Method Details
-
start
-
requestInput
-
conversationAbandoned
- Specified by:
conversationAbandoned
in interfaceConversationAbandonedListener
-
setConversation
- Specified by:
setConversation
in interfaceConversationCanceller
-
cancelBasedOnInput
public boolean cancelBasedOnInput(@NotNull @NotNull ConversationContext context, @NotNull @NotNull String input) - Specified by:
cancelBasedOnInput
in interfaceConversationCanceller
-
clone
- Specified by:
clone
in interfaceConversationCanceller
- Overrides:
clone
in classObject
-