MessageExtensions<TState>.OnBotMessagePreviewSend Method

Definition

Overloads

OnBotMessagePreviewSend(MultipleRouteSelector, BotMessagePreviewSendHandler<TState>)

Registers a handler to process the 'send' action of a message that's being previewed by the user prior to sending.

OnBotMessagePreviewSend(RouteSelectorAsync, BotMessagePreviewSendHandler<TState>)

Registers a handler to process the 'send' action of a message that's being previewed by the user prior to sending.

OnBotMessagePreviewSend(String, BotMessagePreviewSendHandler<TState>)

Registers a handler to process the 'send' action of a message that's being previewed by the user prior to sending.

OnBotMessagePreviewSend(Regex, BotMessagePreviewSendHandler<TState>)

Registers a handler to process the 'send' action of a message that's being previewed by the user prior to sending.

OnBotMessagePreviewSend(MultipleRouteSelector, BotMessagePreviewSendHandler<TState>)

Registers a handler to process the 'send' action of a message that's being previewed by the user prior to sending.

public Microsoft.Teams.AI.Application<TState> OnBotMessagePreviewSend(Microsoft.Teams.AI.MultipleRouteSelector routeSelectors, Microsoft.Teams.AI.BotMessagePreviewSendHandler<TState> handler);
member this.OnBotMessagePreviewSend : Microsoft.Teams.AI.MultipleRouteSelector * Microsoft.Teams.AI.BotMessagePreviewSendHandler<'State (requires 'State :> Microsoft.Teams.AI.State.TurnState and 'State : (new : unit -> 'State))> -> Microsoft.Teams.AI.Application<'State (requires 'State :> Microsoft.Teams.AI.State.TurnState and 'State : (new : unit -> 'State))>
Public Function OnBotMessagePreviewSend (routeSelectors As MultipleRouteSelector, handler As BotMessagePreviewSendHandler(Of TState)) As Application(Of TState)

Parameters

routeSelectors
MultipleRouteSelector

Combination of String, Regex, and RouteSelectorAsync selectors.

handler
BotMessagePreviewSendHandler<TState>

Function to call when the route is triggered.

Returns

The application instance for chaining purposes.

Applies to

OnBotMessagePreviewSend(RouteSelectorAsync, BotMessagePreviewSendHandler<TState>)

Registers a handler to process the 'send' action of a message that's being previewed by the user prior to sending.

public Microsoft.Teams.AI.Application<TState> OnBotMessagePreviewSend(Microsoft.Teams.AI.RouteSelectorAsync routeSelector, Microsoft.Teams.AI.BotMessagePreviewSendHandler<TState> handler);
member this.OnBotMessagePreviewSend : Microsoft.Teams.AI.RouteSelectorAsync * Microsoft.Teams.AI.BotMessagePreviewSendHandler<'State (requires 'State :> Microsoft.Teams.AI.State.TurnState and 'State : (new : unit -> 'State))> -> Microsoft.Teams.AI.Application<'State (requires 'State :> Microsoft.Teams.AI.State.TurnState and 'State : (new : unit -> 'State))>
Public Function OnBotMessagePreviewSend (routeSelector As RouteSelectorAsync, handler As BotMessagePreviewSendHandler(Of TState)) As Application(Of TState)

Parameters

routeSelector
RouteSelectorAsync

Function that's used to select a route. The function returning true triggers the route.

handler
BotMessagePreviewSendHandler<TState>

Function to call when the route is triggered.

Returns

The application instance for chaining purposes.

Applies to

OnBotMessagePreviewSend(String, BotMessagePreviewSendHandler<TState>)

Registers a handler to process the 'send' action of a message that's being previewed by the user prior to sending.

public Microsoft.Teams.AI.Application<TState> OnBotMessagePreviewSend(string commandId, Microsoft.Teams.AI.BotMessagePreviewSendHandler<TState> handler);
member this.OnBotMessagePreviewSend : string * Microsoft.Teams.AI.BotMessagePreviewSendHandler<'State (requires 'State :> Microsoft.Teams.AI.State.TurnState and 'State : (new : unit -> 'State))> -> Microsoft.Teams.AI.Application<'State (requires 'State :> Microsoft.Teams.AI.State.TurnState and 'State : (new : unit -> 'State))>
Public Function OnBotMessagePreviewSend (commandId As String, handler As BotMessagePreviewSendHandler(Of TState)) As Application(Of TState)

Parameters

commandId
String

ID of the command to register the handler for.

handler
BotMessagePreviewSendHandler<TState>

Function to call when the command is received.

Returns

The application instance for chaining purposes.

Applies to

OnBotMessagePreviewSend(Regex, BotMessagePreviewSendHandler<TState>)

Registers a handler to process the 'send' action of a message that's being previewed by the user prior to sending.

public Microsoft.Teams.AI.Application<TState> OnBotMessagePreviewSend(System.Text.RegularExpressions.Regex commandIdPattern, Microsoft.Teams.AI.BotMessagePreviewSendHandler<TState> handler);
member this.OnBotMessagePreviewSend : System.Text.RegularExpressions.Regex * Microsoft.Teams.AI.BotMessagePreviewSendHandler<'State (requires 'State :> Microsoft.Teams.AI.State.TurnState and 'State : (new : unit -> 'State))> -> Microsoft.Teams.AI.Application<'State (requires 'State :> Microsoft.Teams.AI.State.TurnState and 'State : (new : unit -> 'State))>
Public Function OnBotMessagePreviewSend (commandIdPattern As Regex, handler As BotMessagePreviewSendHandler(Of TState)) As Application(Of TState)

Parameters

commandIdPattern
Regex

Regular expression to match against the ID of the command to register the handler for.

handler
BotMessagePreviewSendHandler<TState>

Function to call when the command is received.

Returns

The application instance for chaining purposes.

Applies to