Share via


Extensions.InterruptAsync<T,R> Method

Definition

Interrupt the waiting dialog with a new dialog

public static System.Threading.Tasks.Task InterruptAsync<T,R> (this Microsoft.Bot.Builder.Dialogs.Internals.IDialogTask task, Microsoft.Bot.Builder.Dialogs.IDialog<T> dialog, R item, System.Threading.CancellationToken token);
static member InterruptAsync : Microsoft.Bot.Builder.Dialogs.Internals.IDialogTask * Microsoft.Bot.Builder.Dialogs.IDialog<'T> * 'R * System.Threading.CancellationToken -> System.Threading.Tasks.Task
<Extension()>
Public Function InterruptAsync(Of T, R) (task As IDialogTask, dialog As IDialog(Of T), item As R, token As CancellationToken) As Task

Type Parameters

T

The type of result expected from the dialog.

R

The type of the item posted to dialog.

Parameters

task
IDialogTask

The dialog task.

dialog
IDialog<T>

The new interrupting dialog.

item
R

The item to forward to the new interrupting dialog.

token
CancellationToken

The cancellation token.

Returns

A task that represents the interruption operation.

Applies to