Prompt<T>.OnPreBubbleEventAsync Methode

Definition

Wird aufgerufen, bevor ein Ereignis in das übergeordnete Element eingeblasen wird.

protected override System.Threading.Tasks.Task<bool> OnPreBubbleEventAsync(Microsoft.Bot.Builder.Dialogs.DialogContext dc, Microsoft.Bot.Builder.Dialogs.DialogEvent e, System.Threading.CancellationToken cancellationToken);
override this.OnPreBubbleEventAsync : Microsoft.Bot.Builder.Dialogs.DialogContext * Microsoft.Bot.Builder.Dialogs.DialogEvent * System.Threading.CancellationToken -> System.Threading.Tasks.Task<bool>
Protected Overrides Function OnPreBubbleEventAsync (dc As DialogContext, e As DialogEvent, cancellationToken As CancellationToken) As Task(Of Boolean)

Parameter

dc
DialogContext

Der Dialogkontext für die aktuelle Unterhaltungswende.

e
DialogEvent

Das ausgelöste Ereignis.

cancellationToken
CancellationToken

Abbruchtoken.

Gibt zurück

Gibt an, ob das Ereignis vom aktuellen Dialogfeld behandelt wird und die weitere Verarbeitung beendet werden soll.

Hinweise

Dies ist ein guter Ort, um das Abfangen eines Ereignisses durchzuführen, da das Zurückgeben von "true" eine weitere Bubbling des Ereignisses an die übergeordneten Dialoge verhindert und auch verhindert, dass untergeordnete Dialogfelder ihre Standardverarbeitung ausführen.

Gilt für: