UNPKG

botbuilder-dialogs-adaptive

Version:

Rule system for the Microsoft BotBuilder dialog system.

50 lines 1.89 kB
/** * @module botbuilder-dialogs-adaptive */ /** * Copyright (c) Microsoft Corporation. All rights reserved. * Licensed under the MIT License. */ import { DialogContext, DialogSet, DialogState } from 'botbuilder-dialogs'; import { ActionState } from './actionState'; import { ActionChangeList } from './actionChangeList'; /** * Extends the [DialogContext](xref:botbuilder-dialogs.DialogContext) with additional methods for manipulating the * executing sequence of actions for an [AdaptiveDialog](xref:botbuilder-dialogs-adaptive.AdaptiveDialog). */ export declare class ActionContext extends DialogContext { private readonly _changeKey; /** * Initializes a new instance of the [ActionContext](xref:botbuilder-dialogs-adaptive.ActionContext) class * * @param dialogs The dialog set to create the action context for. * @param parentDialogContext Parent dialog context. * @param state Current dialog state. * @param actions Current list of remaining actions to execute. * @param changeKey TurnState key for where to persist any changes. */ constructor(dialogs: DialogSet, parentDialogContext: DialogContext, state: DialogState, actions: ActionState[], changeKey: symbol); /** * List of actions being executed. */ actions: ActionState[]; /** * Gets list of changes that are queued to be applied. * * @returns The list of changes queued. */ get changes(): ActionChangeList[]; /** * Queues up a set of changes that will be applied when applyChanges() is called. * * @param changes Plan changes to queue up. */ queueChanges(changes: ActionChangeList): void; /** * Applies any queued up changes. * * @returns True if there were any changes to apply. */ applyChanges(): Promise<boolean>; } //# sourceMappingURL=actionContext.d.ts.map