Class TcpTransport
- Namespace
- DotBoxD.Transports.Tcp
- Assembly
- DotBoxD.Transports.Tcp.dll
TCP client transport implementation.
public sealed class TcpTransport : ITransport, IAsyncDisposable
- Inheritance
-
TcpTransport
- Implements
- Inherited Members
- Extension Methods
Constructors
TcpTransport(string, int)
public TcpTransport(string host, int port)
Parameters
Properties
Connection
Gets the active connection (client-side).
public IRpcChannel? Connection { get; }
Property Value
FrameReadIdleTimeout
Inter-read idle timeout applied to this connection's in-progress frame reads (slow-loris defense). null uses DefaultFrameReadIdleTimeout; InfiniteTimeSpan disables it. See TcpConnection.
public TimeSpan? FrameReadIdleTimeout { get; init; }
Property Value
IsConnected
Gets whether there is an active connection.
public bool IsConnected { get; }
Property Value
Methods
ConnectAsync(CancellationToken)
Establishes a connection (client-side).
public Task ConnectAsync(CancellationToken ct = default)
Parameters
Returns
DisposeAsync()
Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources asynchronously.
public ValueTask DisposeAsync()
Returns
- ValueTask
A task that represents the asynchronous dispose operation.