Interface IWebSocketContext

Namespace
Cratis.Arc.Http
Assembly
Cratis.Arc.Core.dll

Represents an abstraction for WebSocket operations.

public interface IWebSocketContext
Extension Methods

Properties

IsWebSocketRequest

Gets a value indicating whether the request is a WebSocket request.

bool IsWebSocketRequest { get; }

Property Value

bool

Methods

AcceptWebSocket(CancellationToken)

Accepts the WebSocket connection.

Task<IWebSocket> AcceptWebSocket(CancellationToken cancellationToken = default)

Parameters

cancellationToken CancellationToken

Cancellation token.

Returns

Task<IWebSocket>

A IWebSocket for communication.