UNPKG

botbuilder-dialogs-adaptive

Version:

Rule system for the Microsoft BotBuilder dialog system.

81 lines 3.56 kB
/** * @module botbuilder-dialogs-adaptive */ /** * Copyright (c) Microsoft Corporation. All rights reserved. * Licensed under the MIT License. */ import { BoolProperty, DialogProperty, ObjectProperty } from '../properties'; import { DialogExpression } from '../expressions'; import { BoolExpression, ObjectExpression } from 'adaptive-expressions'; import { Dialog, DialogDependencies, DialogContext, DialogTurnResult, Converter, ConverterFactory, DialogConfiguration } from 'botbuilder-dialogs'; export interface BaseInvokeDialogConfiguration extends DialogConfiguration { options?: ObjectProperty<object>; dialog?: DialogProperty; activityProcessed?: BoolProperty; } /** * Action which calls another [Dialog](xref:botbuilder-dialogs.Dialog). */ export declare class BaseInvokeDialog<O extends object = {}> extends Dialog<O> implements DialogDependencies, BaseInvokeDialogConfiguration { /** * Initializes a new instance of the [BaseInvokeDialog](xref:botbuilder-dialogs-adaptive.BaseInvokeDialog) class. * * @param dialogIdToCall The dialog id. * @param bindingOptions (optional) Binding options. */ constructor(dialogIdToCall?: string, bindingOptions?: O); /** * Configurable options for the dialog. */ options: ObjectExpression<object>; /** * The dialog to call. */ dialog: DialogExpression; /** * A value indicating whether to have the new dialog should process the activity. */ activityProcessed: BoolExpression; /** * @param property The key of the conditional selector configuration. * @returns The converter for the selector configuration. */ getConverter(property: keyof BaseInvokeDialogConfiguration): Converter | ConverterFactory; /** * Called when the [Dialog](xref:botbuilder-dialogs.Dialog) is started and pushed onto the dialog stack. * * @remarks Method not implemented. * @param _dc The [DialogContext](xref:botbuilder-dialogs.DialogContext) for the current turn of conversation. * @param _options Optional. Initial information to pass to the dialog. */ beginDialog(_dc: DialogContext, _options?: O): Promise<DialogTurnResult<any>>; /** * Gets the child [Dialog](xref:botbuilder-dialogs.Dialog) dependencies so they can be added to the containers [Dialog](xref:botbuilder-dialogs.Dialog) set. * * @returns The child [Dialog](xref:botbuilder-dialogs.Dialog) dependencies. */ getDependencies(): Dialog<{}>[]; /** * @protected * Builds the compute Id for the [Dialog](xref:botbuilder-dialogs.Dialog). * @returns A `string` representing the compute Id. */ protected onComputeId(): string; /** * @protected * Resolve Dialog Expression as either [Dialog](xref:botbuilder-dialogs.Dialog), or [StringExpression](xref:adaptive-expressions.StringExpression) to get `dialogid`. * @param dc The [DialogContext](xref:botbuilder-dialogs.DialogContext) for the current turn of conversation. * @returns The dialog. */ protected resolveDialog(dc: DialogContext): Dialog; /** * @protected * BindOptions - evaluate expressions in options. * @param dc The [DialogContext](xref:botbuilder-dialogs.DialogContext) for the current turn of conversation. * @param options Options to bind. * @returns The merged options with expressions bound to values. */ protected bindOptions(dc: DialogContext, options: object): object; } //# sourceMappingURL=baseInvokeDialog.d.ts.map