public static class BotDefinition.Companion
public long getDefaultBreath()
Convenient default value in ms to wait before next answer sentence. 1s by default.
public void setDefaultBreath(long p)
Convenient default value in ms to wait before next answer sentence. 1s by default.
@NotNull public Intent findIntent(@NotNull java.util.List<? extends ai.tock.bot.definition.StoryDefinition> stories, @NotNull java.lang.String intent)
Finds an intent from an intent name and a list of interface StoryDefinition.
Is no valid intent found, returns unknown.
interface StoryDefinition,
unknown@NotNull public StoryDefinition findStoryDefinition(@NotNull java.util.List<? extends ai.tock.bot.definition.StoryDefinition> stories, @Nullable java.lang.String intent, @NotNull StoryDefinition unknownStory, @NotNull StoryDefinition keywordStory)
Finds a interface StoryDefinition from a list of interface StoryDefinition and an intent name.
Is no valid interface StoryDefinition found, returns the unknownStory.