UdpClientTransportConnectAsync Method
Creates a new connection to a server
Namespace: ARSoft.Tools.Net.DnsAssembly: ARSoft.Tools.Net (in ARSoft.Tools.Net.dll) Version: 3.6.1+aaafdcd61f068318c11734f7b3c59c69371c0549
public Task<IClientConnection?> ConnectAsync(
DnsClientEndpointInfo endpointInfo,
int queryTimeout,
CancellationToken token = default
)
Public Function ConnectAsync (
endpointInfo As DnsClientEndpointInfo,
queryTimeout As Integer,
Optional token As CancellationToken = Nothing
) As Task(Of IClientConnection)
public:
virtual Task<IClientConnection^>^ ConnectAsync(
DnsClientEndpointInfo^ endpointInfo,
int queryTimeout,
CancellationToken token = CancellationToken()
) sealed
abstract ConnectAsync :
endpointInfo : DnsClientEndpointInfo *
queryTimeout : int *
?token : CancellationToken
(* Defaults:
let _token = defaultArg token new CancellationToken()
*)
-> Task<IClientConnection>
override ConnectAsync :
endpointInfo : DnsClientEndpointInfo *
queryTimeout : int *
?token : CancellationToken
(* Defaults:
let _token = defaultArg token new CancellationToken()
*)
-> Task<IClientConnection>
- endpointInfo DnsClientEndpointInfo
- The endpoint to connect to
- queryTimeout Int32
- The query timeout in milliseconds
- token CancellationToken (Optional)
- The token to monitor cancellation requests
TaskIClientConnectionA connection to the specified server or null, if the connection could not be established
IClientTransportConnectAsync(DnsClientEndpointInfo, Int32, CancellationToken)