UNPKG

botbuilder-dialogs-adaptive

Version:

Rule system for the Microsoft BotBuilder dialog system.

59 lines 2.31 kB
/** * @module botbuilder-dialogs-adaptive */ /** * Copyright (c) Microsoft Corporation. All rights reserved. * Licensed under the MIT License. */ import { Activity } from 'botbuilder'; import { BoolProperty, StringProperty, TemplateInterfaceProperty } from '../properties'; import { StringExpression, BoolExpression } from 'adaptive-expressions'; import { Converter, ConverterFactory, Dialog, DialogConfiguration, DialogContext, DialogStateManager, DialogTurnResult, TemplateInterface } from 'botbuilder-dialogs'; type D = DialogStateManager & { utterance: string; }; export interface UpdateActivityConfiguration extends DialogConfiguration { activity?: TemplateInterfaceProperty<Partial<Activity>, D>; activityId?: StringProperty; disabled?: BoolProperty; } /** * Update an activity with replacement. */ export declare class UpdateActivity<O extends object = {}> extends Dialog<O> implements UpdateActivityConfiguration { static $kind: string; constructor(); /** * Gets or sets template for the activity. */ activity: TemplateInterface<Partial<Activity>, D & O>; /** * The expression which resolves to the activityId to update. */ activityId: StringExpression; /** * An optional expression which if is true will disable this action. */ disabled?: BoolExpression; /** * @param property The key of the conditional selector configuration. * @returns The converter for the selector configuration. */ getConverter(property: keyof UpdateActivityConfiguration): Converter | ConverterFactory; /** * Starts a new [Dialog](xref:botbuilder-dialogs.Dialog) and pushes it onto the dialog stack. * * @param dc The [DialogContext](xref:botbuilder-dialogs.DialogContext) for the current turn of conversation. * @param options Optional. Initial information to pass to the dialog. * @returns A `Promise` representing the asynchronous operation. */ beginDialog(dc: DialogContext, options?: O): Promise<DialogTurnResult>; /** * @protected * Builds the compute Id for the [Dialog](xref:botbuilder-dialogs.Dialog). * @returns A `string` representing the compute Id. */ protected onComputeId(): string; } export {}; //# sourceMappingURL=updateActivity.d.ts.map