WebSocketsDependencyInjectionExtensions.AddWebSockets Method

Definition

Extension method for IServiceCollection to add WebSockets configuration.

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

Parameters

services
IServiceCollection

The service collection to add WebSockets specific configuration to.

configure
Action<WebSocketOptions>

The configuration callback to setup WebSocketOptions.

Returns

Applies to