Sdílet prostřednictvím


IHttpWebSocketFeature.AcceptAsync(WebSocketAcceptContext) Metoda

Definice

Pokusí se upgradovat požadavek na WebSocket. Než to vyvoláte, zkontrolujte IsWebSocketRequest to.

public:
 System::Threading::Tasks::Task<System::Net::WebSockets::WebSocket ^> ^ AcceptAsync(Microsoft::AspNetCore::Http::WebSocketAcceptContext ^ context);
public System.Threading.Tasks.Task<System.Net.WebSockets.WebSocket> AcceptAsync (Microsoft.AspNetCore.Http.WebSocketAcceptContext context);
abstract member AcceptAsync : Microsoft.AspNetCore.Http.WebSocketAcceptContext -> System.Threading.Tasks.Task<System.Net.WebSockets.WebSocket>
Public Function AcceptAsync (context As WebSocketAcceptContext) As Task(Of WebSocket)

Parametry

Návraty

Úloha WebSocket.

Platí pro