ActivityHandler.OnMessageDeleteActivityAsync 方法

定义

重写派生类中的此项,以提供特定于 MessageDelete 活动的逻辑,例如聊天逻辑。

protected virtual System.Threading.Tasks.Task OnMessageDeleteActivityAsync (Microsoft.Bot.Builder.ITurnContext<Microsoft.Bot.Schema.IMessageDeleteActivity> turnContext, System.Threading.CancellationToken cancellationToken);
abstract member OnMessageDeleteActivityAsync : Microsoft.Bot.Builder.ITurnContext<Microsoft.Bot.Schema.IMessageDeleteActivity> * System.Threading.CancellationToken -> System.Threading.Tasks.Task
override this.OnMessageDeleteActivityAsync : Microsoft.Bot.Builder.ITurnContext<Microsoft.Bot.Schema.IMessageDeleteActivity> * System.Threading.CancellationToken -> System.Threading.Tasks.Task
Protected Overridable Function OnMessageDeleteActivityAsync (turnContext As ITurnContext(Of IMessageDeleteActivity), cancellationToken As CancellationToken) As Task

参数

turnContext
ITurnContext<IMessageDeleteActivity>

此轮次的强类型上下文对象。

cancellationToken
CancellationToken

其他对象或线程可以使用的取消令牌来接收取消通知。

返回

表示要执行的工作的任务。

注解

OnTurnAsync(ITurnContext, CancellationToken) 方法收到消息删除活动时,它将调用此方法。

适用于

另请参阅