Compartir a través de


WebSocketsDependencyInjectionExtensions.AddWebSockets Método

Definición

Método de extensión para IServiceCollection agregar la configuración de WebSockets.

public:
[System::Runtime::CompilerServices::Extension]
 static Microsoft::Extensions::DependencyInjection::IServiceCollection ^ AddWebSockets(Microsoft::Extensions::DependencyInjection::IServiceCollection ^ services, Action<Microsoft::AspNetCore::Builder::WebSocketOptions ^> ^ configure);
public static Microsoft.Extensions.DependencyInjection.IServiceCollection AddWebSockets (this Microsoft.Extensions.DependencyInjection.IServiceCollection services, Action<Microsoft.AspNetCore.Builder.WebSocketOptions> configure);
static member AddWebSockets : Microsoft.Extensions.DependencyInjection.IServiceCollection * Action<Microsoft.AspNetCore.Builder.WebSocketOptions> -> Microsoft.Extensions.DependencyInjection.IServiceCollection
<Extension()>
Public Function AddWebSockets (services As IServiceCollection, configure As Action(Of WebSocketOptions)) As IServiceCollection

Parámetros

services
IServiceCollection

Colección de servicios a la que se va a agregar una configuración específica de WebSockets.

configure
Action<WebSocketOptions>

Devolución de llamada de configuración para configurar WebSocketOptions.

Devoluciones

Se aplica a