Index

A B C E F G H I N O P Q R S T U V W 
All Classes and Interfaces|All Packages

A

acceptInput(UUID, MessageType) - Method in class com.mrivanplays.conversations.base.ConversationManager
Handles the specified message input for the specified UUID conversationPartner's Conversation if any.
acceptInput(MessageType) - Method in class com.mrivanplays.conversations.base.Conversation
Handles the specified message input.
addQuestion(Function<ChainedQuestion.ComputeContext<MessageType, SenderType>, Question<MessageType, SenderType>>) - Method in class com.mrivanplays.conversations.base.question.ChainedQuestion
Add a compute method for a question.

B

build() - Method in class com.mrivanplays.conversations.base.Conversation.Builder
Builds this builder into a Conversation
build() - Method in class com.mrivanplays.conversations.base.question.Question.Builder
Builds this builder into a Question

C

cancel() - Method in interface com.mrivanplays.conversations.base.timeout.TimeoutTask
Cancel this timeout task if not cancelled already.
ChainedQuestion<MessageType,SenderType extends ConversationPartner<MessageType>> - Class in com.mrivanplays.conversations.base.question
Represents a chained question.
ChainedQuestion(Question<MessageType, SenderType>) - Constructor for class com.mrivanplays.conversations.base.question.ChainedQuestion
 
ChainedQuestion.ComputeContext<MessageType,SenderType extends ConversationPartner<MessageType>> - Class in com.mrivanplays.conversations.base.question
Represents a context, with which a Question can be computed.
chainedQuestions(ChainedQuestion<MessageType, SenderType>) - Method in class com.mrivanplays.conversations.base.Conversation.Builder
Specify a ChainedQuestion to be sent to the conversation partner.
com.mrivanplays.conversations.base - package com.mrivanplays.conversations.base
 
com.mrivanplays.conversations.base.question - package com.mrivanplays.conversations.base.question
 
com.mrivanplays.conversations.base.timeout - package com.mrivanplays.conversations.base.timeout
 
ComputeContext(Question<MessageType, SenderType>, MessageType, SenderType) - Constructor for class com.mrivanplays.conversations.base.question.ChainedQuestion.ComputeContext
Construct a new compute context.
Conversation<MessageType,SenderType extends ConversationPartner<MessageType>> - Class in com.mrivanplays.conversations.base
Represents a conversation.
Conversation.Builder<MessageType,SenderType extends ConversationPartner<MessageType>> - Class in com.mrivanplays.conversations.base
Represents a builder of Conversation
ConversationContext<MessageType,SenderType extends ConversationPartner<MessageType>> - Class in com.mrivanplays.conversations.base
Represents a ended Conversation's context.
ConversationContext.EndState - Enum in com.mrivanplays.conversations.base
Represents an enum of states of how the context used in was created.
ConversationManager<MessageType,SenderType extends ConversationPartner<MessageType>> - Class in com.mrivanplays.conversations.base
Represents a manager of conversations
ConversationManager() - Constructor for class com.mrivanplays.conversations.base.ConversationManager
 
ConversationPartner<MessageType> - Interface in com.mrivanplays.conversations.base
Represents a conversation partner

E

ExecutorServiceTimeoutScheduler - Class in com.mrivanplays.conversations.base.timeout
Represents a TimeoutScheduler implementation using java's ScheduledExecutorService
ExecutorServiceTimeoutScheduler() - Constructor for class com.mrivanplays.conversations.base.timeout.ExecutorServiceTimeoutScheduler
 
ExecutorServiceTimeoutScheduler(ScheduledExecutorService) - Constructor for class com.mrivanplays.conversations.base.timeout.ExecutorServiceTimeoutScheduler
 

F

fail(MessageType) - Static method in class com.mrivanplays.conversations.base.question.InputValidator.ValidationResult
Returns a failure result with the specified message
fail(MessageType, boolean) - Static method in class com.mrivanplays.conversations.base.question.InputValidator.ValidationResult
Returns a failure result with the specified message
fail(MessageType, boolean, boolean) - Static method in class com.mrivanplays.conversations.base.question.InputValidator.ValidationResult
Returns a failure result with the specified message.

G

getConversationPartner() - Method in class com.mrivanplays.conversations.base.Conversation
Returns the conversation partner of this conversation.
getConversationPartner() - Method in class com.mrivanplays.conversations.base.ConversationContext
Returns the conversation partner.
getConversationPartner() - Method in class com.mrivanplays.conversations.base.question.ChainedQuestion.ComputeContext
getEndState() - Method in class com.mrivanplays.conversations.base.ConversationContext
Returns the state of how this context was created.
getErrorMessage() - Method in class com.mrivanplays.conversations.base.question.InputValidator.ValidationResult
Returns the error message, which may be null.
getFirstQuestion() - Method in class com.mrivanplays.conversations.base.question.ChainedQuestion
Returns the first Question, or the question that a Conversation can start with.
getIdentifier() - Method in class com.mrivanplays.conversations.base.question.Question
Returns the identifier of this question.
getInput(String) - Method in class com.mrivanplays.conversations.base.ConversationContext
Returns the answer of the Question, matching the specified questionIdentifier
getInputMessage() - Method in class com.mrivanplays.conversations.base.question.ChainedQuestion.ComputeContext
Returns the input message.
getInputValidator() - Method in class com.mrivanplays.conversations.base.question.Question
Returns the InputValidator
getMessage() - Method in class com.mrivanplays.conversations.base.question.Question
Returns the question message of this question.
getNextQuestion(ChainedQuestion.ComputeContext<MessageType, SenderType>) - Method in class com.mrivanplays.conversations.base.question.ChainedQuestion
Computes the next question with the specified compute context.
getPreviousQuestion() - Method in class com.mrivanplays.conversations.base.question.ChainedQuestion.ComputeContext
Returns the previous asked question.
getQuestionIdentifierEndedOn() - Method in class com.mrivanplays.conversations.base.ConversationContext
Returns the question identifier on which the Conversation this context originated from ended.
getTimeout() - Method in class com.mrivanplays.conversations.base.question.Question
Returns the timeout of this question.
getTimeoutUnit() - Method in class com.mrivanplays.conversations.base.question.Question
Returns the timeout TimeUnit of this question.
getUniqueIdentifier() - Method in interface com.mrivanplays.conversations.base.ConversationPartner
Returns the unique identifier UUID of this conversation partner.
getWhenTimeout() - Method in class com.mrivanplays.conversations.base.question.Question
Returns the Consumer which would be run when the question expires (time out).

H

hasActiveConversation(UUID) - Method in class com.mrivanplays.conversations.base.ConversationManager
Returns whether the specified UUID conversationPartner has an ongoing Conversation.
hasCalled() - Method in interface com.mrivanplays.conversations.base.timeout.TimeoutTask
Returns whether the task was called.
hasEnded() - Method in class com.mrivanplays.conversations.base.Conversation
Returns whether this conversation has ended.

I

INPUT_VALIDATION_HANDLER_FAIL - Enum constant in enum com.mrivanplays.conversations.base.ConversationContext.EndState
Indicates that a question's input validator has failed and had the instruction to call end.
InputValidator<MessageType> - Interface in com.mrivanplays.conversations.base.question
Represents a validator of a Question input.
InputValidator.ValidationResult<MessageType> - Class in com.mrivanplays.conversations.base.question
Represents a validation result.
isSuccessful() - Method in class com.mrivanplays.conversations.base.question.InputValidator.ValidationResult
Returns whether this validation result is a success.

N

newBuilder() - Static method in class com.mrivanplays.conversations.base.Conversation
Creates a new Conversation.Builder
newBuilder() - Static method in class com.mrivanplays.conversations.base.question.Question
Creates a new Question.Builder
newBuilder(Conversation<MessageType, SenderType>) - Static method in class com.mrivanplays.conversations.base.Conversation
 
newBuilder(Question<MessageType, SenderType>) - Static method in class com.mrivanplays.conversations.base.question.Question
 

O

of(String, MessageType) - Static method in class com.mrivanplays.conversations.base.question.Question
Creates a simple question, consisting of its identifier and message.
of(SenderType, Map<String, MessageType>, ConversationContext.EndState, String) - Static method in class com.mrivanplays.conversations.base.ConversationContext
Create a new ConversationContext

P

parentManager(ConversationManager<MessageType, SenderType>) - Method in class com.mrivanplays.conversations.base.Conversation.Builder
Specify the parent ConversationManager of the built conversation.
PARTNER_DISCONNECT - Enum constant in enum com.mrivanplays.conversations.base.ConversationContext.EndState
Indicates that the conversation partner has disconnected.

Q

Question<MessageType,SenderType extends ConversationPartner<MessageType>> - Class in com.mrivanplays.conversations.base.question
Represents a question, which would be asked to a ConversationPartner.
Question.Builder<MessageType,SenderType extends ConversationPartner<MessageType>> - Class in com.mrivanplays.conversations.base.question
Represents a builder of Question

R

registerConversation(Conversation<MessageType, SenderType>) - Method in class com.mrivanplays.conversations.base.ConversationManager
Registers a new Conversation.

S

schedule(Runnable, long, TimeUnit) - Method in class com.mrivanplays.conversations.base.timeout.ExecutorServiceTimeoutScheduler
Schedules the specified task to run after the specified time in the specified TimeUnit timeUnit
schedule(Runnable, long, TimeUnit) - Method in interface com.mrivanplays.conversations.base.timeout.TimeoutScheduler
Schedules the specified task to run after the specified time in the specified TimeUnit timeUnit
sendMessage(MessageType) - Method in interface com.mrivanplays.conversations.base.ConversationPartner
Sends the specified message to this conversation partner.
shallAskQuestionAgain() - Method in class com.mrivanplays.conversations.base.question.InputValidator.ValidationResult
Returns whether we should send the question again to the conversation partner.
shallCallDoneState() - Method in class com.mrivanplays.conversations.base.question.InputValidator.ValidationResult
Returns whether we shall call the conversation done.
shutdown() - Method in class com.mrivanplays.conversations.base.timeout.ExecutorServiceTimeoutScheduler
(Optional to implement) Shuts down any executor if needed.
shutdown() - Method in interface com.mrivanplays.conversations.base.timeout.TimeoutScheduler
(Optional to implement) Shuts down any executor if needed.
start() - Method in class com.mrivanplays.conversations.base.Conversation
Starts the conversation by sending the first question.
success() - Static method in class com.mrivanplays.conversations.base.question.InputValidator.ValidationResult
Returns a single success result.
SUCCESS - Enum constant in enum com.mrivanplays.conversations.base.ConversationContext.EndState
Indicates a successful ending state

T

TIMEOUT - Enum constant in enum com.mrivanplays.conversations.base.ConversationContext.EndState
Indicates a timeout has occurred
TimeoutScheduler - Interface in com.mrivanplays.conversations.base.timeout
Represents a timeout task scheduler.
TimeoutTask - Interface in com.mrivanplays.conversations.base.timeout
Represents a basic timeout task.

U

UNKNOWN - Enum constant in enum com.mrivanplays.conversations.base.ConversationContext.EndState
Indicates that the conversation was ended by an unknown reason.
unregisterConversation(UUID) - Method in class com.mrivanplays.conversations.base.ConversationManager
Unregisters the Conversation of the specified UUID conversationPartner.
unregisterConversation(UUID, ConversationContext.EndState) - Method in class com.mrivanplays.conversations.base.ConversationManager
 

V

validate(MessageType) - Method in interface com.mrivanplays.conversations.base.question.InputValidator
Validates the message input and returns a InputValidator.ValidationResult
valueOf(String) - Static method in enum com.mrivanplays.conversations.base.ConversationContext.EndState
Returns the enum constant of this type with the specified name.
values() - Static method in enum com.mrivanplays.conversations.base.ConversationContext.EndState
Returns an array containing the constants of this enum type, in the order they are declared.

W

whenDone(Consumer<ConversationContext<MessageType, SenderType>>) - Method in class com.mrivanplays.conversations.base.Conversation.Builder
Specify the handler when this conversation ends.
whenTimeout(Consumer<SenderType>) - Method in class com.mrivanplays.conversations.base.question.Question.Builder
Specify the action to be run when the timeout runs out.
withConversationPartner(SenderType) - Method in class com.mrivanplays.conversations.base.Conversation.Builder
Specify the conversation partner of the built conversation.
withIdentifier(String) - Method in class com.mrivanplays.conversations.base.question.Question.Builder
Specify the identifier of the question.
withInputValidator(InputValidator<MessageType>) - Method in class com.mrivanplays.conversations.base.question.Question.Builder
Specify the InputValidator
withMessage(MessageType) - Method in class com.mrivanplays.conversations.base.question.Question.Builder
Specify the message question of the question.
withQuestion(Question<MessageType, SenderType>) - Method in class com.mrivanplays.conversations.base.Conversation.Builder
Specify a Question to be sent to the conversation partner.
withTimeout(long, TimeUnit) - Method in class com.mrivanplays.conversations.base.question.Question.Builder
Specify the timeout of this question.
withTimeoutScheduler(TimeoutScheduler) - Method in class com.mrivanplays.conversations.base.Conversation.Builder
Specify the TimeoutScheduler of the build conversation.
A B C E F G H I N O P Q R S T U V W 
All Classes and Interfaces|All Packages