Improve XML documentation coverage across src modules and sync generated analysis artifacts.
This commit is contained in:
@@ -17,6 +17,11 @@ public sealed class WebSocketStreamAdapter : Stream
|
||||
private int _readCount;
|
||||
private bool _disposed;
|
||||
|
||||
/// <summary>
|
||||
/// Creates a stream adapter for a WebSocket-backed leaf-node transport.
|
||||
/// </summary>
|
||||
/// <param name="ws">WebSocket transport used for framed binary I/O.</param>
|
||||
/// <param name="initialBufferSize">Initial receive staging-buffer size.</param>
|
||||
public WebSocketStreamAdapter(SystemWebSocket ws, int initialBufferSize = 4096)
|
||||
{
|
||||
_ws = ws ?? throw new ArgumentNullException(nameof(ws));
|
||||
@@ -34,10 +39,15 @@ public sealed class WebSocketStreamAdapter : Stream
|
||||
public override bool CanSeek => false;
|
||||
|
||||
// Telemetry properties
|
||||
/// <summary>Whether the underlying WebSocket is currently open.</summary>
|
||||
public bool IsConnected => _ws.State == WebSocketState.Open;
|
||||
/// <summary>Total bytes read from received WebSocket messages.</summary>
|
||||
public long BytesRead { get; private set; }
|
||||
/// <summary>Total bytes written to outbound WebSocket messages.</summary>
|
||||
public long BytesWritten { get; private set; }
|
||||
/// <summary>Total completed WebSocket messages read.</summary>
|
||||
public int MessagesRead { get; private set; }
|
||||
/// <summary>Total completed WebSocket messages written.</summary>
|
||||
public int MessagesWritten { get; private set; }
|
||||
|
||||
/// <inheritdoc />
|
||||
@@ -196,12 +206,18 @@ public sealed class WebSocketStreamAdapter : Stream
|
||||
get => throw new NotSupportedException();
|
||||
set => throw new NotSupportedException();
|
||||
}
|
||||
/// <inheritdoc />
|
||||
public override long Seek(long offset, SeekOrigin origin) => throw new NotSupportedException();
|
||||
/// <inheritdoc />
|
||||
public override void SetLength(long value) => throw new NotSupportedException();
|
||||
/// <inheritdoc />
|
||||
public override int Read(byte[] buffer, int offset, int count) => throw new NotSupportedException("Use async methods");
|
||||
/// <inheritdoc />
|
||||
public override void Write(byte[] buffer, int offset, int count) => throw new NotSupportedException("Use async methods");
|
||||
/// <inheritdoc />
|
||||
public override void Flush() { }
|
||||
|
||||
/// <inheritdoc />
|
||||
protected override void Dispose(bool disposing)
|
||||
{
|
||||
if (_disposed)
|
||||
|
||||
Reference in New Issue
Block a user