public class BotBusMockContext
The context of the test.
public BotBusMockContext(@NotNull
ai.tock.bot.engine.user.UserTimeline userTimeline,
@NotNull
ai.tock.bot.engine.dialog.Dialog dialog,
@NotNull
ai.tock.bot.engine.dialog.Story story,
@NotNull
ai.tock.bot.engine.action.Action firstAction,
@NotNull
ai.tock.bot.definition.BotDefinition botDefinition,
@NotNull
ai.tock.translator.I18nKeyProvider i18nProvider,
@NotNull
ai.tock.translator.UserInterfaceType userInterfaceType,
@NotNull
ai.tock.bot.connector.ConnectorType connectorType,
@NotNull
TestContext testContext,
@NotNull
java.util.List<ai.tock.bot.engine.dialog.Snapshot> snapshots)
The context of the test.
public BotBusMockContext(@NotNull
java.lang.String applicationId,
@NotNull
ai.tock.bot.engine.user.PlayerId userId,
@NotNull
ai.tock.bot.engine.user.PlayerId botId,
@NotNull
ai.tock.bot.definition.BotDefinition botDefinition,
@NotNull
ai.tock.bot.definition.StoryDefinition storyDefinition,
@NotNull
ai.tock.bot.engine.action.Action action,
@NotNull
ai.tock.translator.UserInterfaceType userInterfaceType,
@NotNull
ai.tock.bot.engine.user.UserPreferences userPreferences,
@NotNull
ai.tock.bot.connector.ConnectorType connectorType,
@NotNull
TestContext testContext)
public BotBusMockContext(@NotNull
ai.tock.bot.definition.BotDefinition botDefinition,
@NotNull
ai.tock.bot.definition.StoryDefinition storyDefinition,
@NotNull
java.lang.String applicationId,
@NotNull
ai.tock.bot.engine.user.PlayerId userId,
@NotNull
ai.tock.bot.engine.user.PlayerId botId,
@NotNull
ai.tock.bot.engine.action.Action action,
@NotNull
ai.tock.translator.UserInterfaceType userInterfaceType,
@NotNull
ai.tock.bot.engine.user.UserPreferences userPreferences,
@NotNull
ai.tock.bot.connector.ConnectorType connectorType,
@NotNull
TestContext testContext)
@NotNull public java.lang.String getApplicationId()
@NotNull public ai.tock.bot.engine.user.PlayerId getBotId()
@NotNull public ai.tock.bot.engine.user.PlayerId getUserId()
@NotNull public ai.tock.bot.engine.user.UserPreferences getUserPreferences()
@NotNull public ai.tock.bot.engine.user.UserPreferences getInitialUserPreferences()
@NotNull public java.util.List<ai.tock.bot.test.BotBusMockLog> getAnswers()
The list of all bot answers recorded.
@NotNull public BotBusMockLog getFirstAnswer()
The first answer recorded.
@NotNull public BotBusMockLog getSecondAnswer()
The second answer recorded.
@NotNull public BotBusMockLog getThirdAnswer()
The third answer recorded.
@NotNull public BotBusMockLog getLastAnswer()
The last answer recorded.
public void resetUserPreferences(@NotNull
ai.tock.bot.engine.user.UserPreferences userPreferences)
Reset user preferences.
@NotNull
public ai.tock.bot.engine.action.SendSentence sentence(@NotNull
java.lang.String text,
@NotNull
ai.tock.bot.engine.dialog.EntityValue... entityValues)
Create a new sentence for this context.
@NotNull
public ai.tock.bot.engine.action.SendSentence sentence(@NotNull
java.lang.String text,
@NotNull
java.util.List<ai.tock.bot.engine.dialog.EntityValue> entityValues)
Create a new sentence for this context.
@NotNull
public ai.tock.bot.engine.action.SendSentence sentence(@NotNull
java.lang.String text,
@Nullable
ai.tock.bot.definition.IntentAware intent,
@NotNull
ai.tock.bot.engine.dialog.EntityValue... entityValues)
Create a new sentence for this context.
@NotNull
public ai.tock.bot.engine.action.SendSentence sentence(@NotNull
java.lang.String text,
@Nullable
ai.tock.bot.definition.IntentAware intent,
@NotNull
java.util.List<ai.tock.bot.engine.dialog.EntityValue> entityValues)
Create a new sentence for this context.
@NotNull
public ai.tock.bot.engine.action.SendSentence sentence(@NotNull
ai.tock.bot.connector.ConnectorMessage message,
@NotNull
ai.tock.bot.engine.dialog.EntityValue... entityValues)
Create a new sentence for this context.
@NotNull
public ai.tock.bot.engine.action.SendSentence sentence(@NotNull
ai.tock.bot.connector.ConnectorMessage message,
@NotNull
java.util.List<ai.tock.bot.engine.dialog.EntityValue> entityValues)
Create a new sentence for this context.
@NotNull
public ai.tock.bot.engine.action.SendSentence sentence(@NotNull
ai.tock.bot.connector.ConnectorMessage message,
@Nullable
ai.tock.bot.definition.IntentAware intent,
@NotNull
ai.tock.bot.engine.dialog.EntityValue... entityValues)
Create a new sentence for this context.
@NotNull
public ai.tock.bot.engine.action.SendSentence sentence(@NotNull
ai.tock.bot.connector.ConnectorMessage message,
@Nullable
ai.tock.bot.definition.IntentAware intent,
@NotNull
java.util.List<ai.tock.bot.engine.dialog.EntityValue> entityValues)
Create a new sentence for this context.
@NotNull
public ai.tock.bot.engine.action.SendChoice choice(@NotNull
java.lang.String intentName,
@NotNull
kotlin.Pair... parameters)
Create a choice for this context.
@NotNull
public ai.tock.bot.engine.action.SendChoice choice(@NotNull
java.lang.String intentName,
@NotNull
ai.tock.bot.definition.StoryStep<? extends ai.tock.bot.definition.StoryHandlerDefinition> step,
@NotNull
kotlin.Pair... parameters)
Create a choice for this context.
@NotNull
public ai.tock.bot.engine.action.SendChoice choice(@NotNull
ai.tock.bot.definition.IntentAware intent,
@NotNull
ai.tock.bot.definition.StoryStep<? extends ai.tock.bot.definition.StoryHandlerDefinition> step,
@NotNull
ai.tock.bot.definition.Parameters parameters)
Create a choice for this context.
@NotNull
public ai.tock.bot.engine.action.SendChoice choice(@NotNull
ai.tock.bot.definition.IntentAware intent,
@NotNull
ai.tock.bot.definition.Parameters parameters)
Create a choice for this context.
@NotNull
public ai.tock.bot.engine.action.SendChoice choiceOfId(@NotNull
java.lang.String choiceId)
Create a choice for this context.
@NotNull public ai.tock.bot.engine.user.UserTimeline getUserTimeline()
public void setUserTimeline(@NotNull
ai.tock.bot.engine.user.UserTimeline p)
@NotNull public ai.tock.bot.engine.dialog.Dialog getDialog()
public void setDialog(@NotNull
ai.tock.bot.engine.dialog.Dialog p)
@NotNull public ai.tock.bot.engine.dialog.Story getStory()
public void setStory(@NotNull
ai.tock.bot.engine.dialog.Story p)
@NotNull public ai.tock.bot.engine.action.Action getFirstAction()
public void setFirstAction(@NotNull
ai.tock.bot.engine.action.Action p)
@NotNull public ai.tock.bot.definition.BotDefinition getBotDefinition()
public void setBotDefinition(@NotNull
ai.tock.bot.definition.BotDefinition p)
@NotNull public ai.tock.translator.I18nKeyProvider getI18nProvider()
public void setI18nProvider(@NotNull
ai.tock.translator.I18nKeyProvider p)
@NotNull public ai.tock.translator.UserInterfaceType getUserInterfaceType()
public void setUserInterfaceType(@NotNull
ai.tock.translator.UserInterfaceType p)
@NotNull public ai.tock.bot.connector.ConnectorType getConnectorType()
public void setConnectorType(@NotNull
ai.tock.bot.connector.ConnectorType p)
@NotNull public TestContext getTestContext()
@NotNull public java.util.List<ai.tock.bot.engine.dialog.Snapshot> getSnapshots()
@NotNull public ai.tock.bot.engine.user.UserTimeline component1()
@NotNull public ai.tock.bot.engine.dialog.Dialog component2()
@NotNull public ai.tock.bot.engine.dialog.Story component3()
@NotNull public ai.tock.bot.engine.action.Action component4()
@NotNull public ai.tock.bot.definition.BotDefinition component5()
@NotNull public ai.tock.translator.I18nKeyProvider component6()
@NotNull public ai.tock.translator.UserInterfaceType component7()
@NotNull public ai.tock.bot.connector.ConnectorType component8()
@NotNull public TestContext component9()
@NotNull public java.util.List<ai.tock.bot.engine.dialog.Snapshot> component10()
@NotNull public BotBusMockContext copy(@NotNull ai.tock.bot.engine.user.UserTimeline userTimeline, @NotNull ai.tock.bot.engine.dialog.Dialog dialog, @NotNull ai.tock.bot.engine.dialog.Story story, @NotNull ai.tock.bot.engine.action.Action firstAction, @NotNull ai.tock.bot.definition.BotDefinition botDefinition, @NotNull ai.tock.translator.I18nKeyProvider i18nProvider, @NotNull ai.tock.translator.UserInterfaceType userInterfaceType, @NotNull ai.tock.bot.connector.ConnectorType connectorType, @NotNull TestContext testContext, @NotNull java.util.List<ai.tock.bot.engine.dialog.Snapshot> snapshots)
The context of the test.
@NotNull public java.lang.String toString()
public int hashCode()
public boolean equals(@Nullable
java.lang.Object p)