Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches

◆ CloseOutputAsyncCore()

async Task System.Net.WebSockets.ManagedWebSocket.CloseOutputAsyncCore ( WebSocketCloseStatus closeStatus,
string statusDescription,
CancellationToken cancellationToken )
inlineprivate

Definition at line 819 of file ManagedWebSocket.cs.

820 {
821 WebSocketValidate.ThrowIfInvalidState(_state, _disposed, s_validCloseOutputStates);
822 await SendCloseFrameAsync(closeStatus, statusDescription, cancellationToken).ConfigureAwait(continueOnCapturedContext: false);
823 lock (StateUpdateLock)
824 {
826 {
827 DisposeCore();
828 }
829 }
830 }
static readonly WebSocketState[] s_validCloseOutputStates
async ValueTask SendCloseFrameAsync(WebSocketCloseStatus closeStatus, string closeStatusDescription, CancellationToken cancellationToken)
ConfiguredValueTaskAwaitable ConfigureAwait(bool continueOnCapturedContext)
Definition ValueTask.cs:312

References System.Net.WebSockets.ManagedWebSocket._disposed, System.Net.WebSockets.ManagedWebSocket._receivedCloseFrame, System.Net.WebSockets.ManagedWebSocket._state, System.cancellationToken, System.Threading.Tasks.ValueTask< TResult >.ConfigureAwait(), System.Net.WebSockets.ManagedWebSocket.DisposeCore(), System.Net.WebSockets.ManagedWebSocket.s_validCloseOutputStates, System.Net.WebSockets.ManagedWebSocket.SendCloseFrameAsync(), System.Net.WebSockets.ManagedWebSocket.StateUpdateLock, and System.Net.WebSockets.WebSocketValidate.ThrowIfInvalidState().

Referenced by System.Net.WebSockets.ManagedWebSocket.CloseOutputAsync().