Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches
QuicConnection.cs
Go to the documentation of this file.
6
7namespace System.Net.Quic;
8
9public sealed class QuicConnection : IDisposable
10{
12
14
16
18
20
22
23 public QuicConnection(EndPoint remoteEndPoint, SslClientAuthenticationOptions? sslClientAuthenticationOptions, IPEndPoint? localEndPoint = null)
24 : this(QuicImplementationProviders.Default, remoteEndPoint, sslClientAuthenticationOptions, localEndPoint)
25 {
26 }
27
32
33 public QuicConnection(QuicImplementationProvider implementationProvider, EndPoint remoteEndPoint, SslClientAuthenticationOptions? sslClientAuthenticationOptions, IPEndPoint? localEndPoint = null)
34 : this(implementationProvider, new QuicClientConnectionOptions
35 {
36 RemoteEndPoint = remoteEndPoint,
37 ClientAuthenticationOptions = sslClientAuthenticationOptions,
38 LocalEndPoint = localEndPoint
39 })
40 {
41 }
42
44 {
45 _provider = implementationProvider.CreateConnection(options);
46 }
47
49 {
50 _provider = provider;
51 }
52
57
62
67
72
77
79 {
80 return new QuicStream(await _provider.AcceptStreamAsync(cancellationToken).ConfigureAwait(continueOnCapturedContext: false));
81 }
82
84 {
85 return _provider.CloseAsync(errorCode, cancellationToken);
86 }
87
88 public void Dispose()
89 {
91 }
92
97
102}
ValueTask WaitForAvailableUnidirectionalStreamsAsync(CancellationToken cancellationToken=default(CancellationToken))
ValueTask CloseAsync(long errorCode, CancellationToken cancellationToken=default(CancellationToken))
ValueTask< QuicStreamProvider > AcceptStreamAsync(CancellationToken cancellationToken=default(CancellationToken))
ValueTask ConnectAsync(CancellationToken cancellationToken=default(CancellationToken))
ValueTask WaitForAvailableBidirectionalStreamsAsync(CancellationToken cancellationToken=default(CancellationToken))
QuicConnectionProvider CreateConnection(QuicClientConnectionOptions options)
QuicConnection(EndPoint remoteEndPoint, SslClientAuthenticationOptions? sslClientAuthenticationOptions, IPEndPoint? localEndPoint=null)
QuicConnection(QuicImplementationProvider implementationProvider, QuicClientConnectionOptions options)
QuicConnection(QuicImplementationProvider implementationProvider, EndPoint remoteEndPoint, SslClientAuthenticationOptions? sslClientAuthenticationOptions, IPEndPoint? localEndPoint=null)
readonly QuicConnectionProvider _provider
QuicConnection(QuicClientConnectionOptions options)
ValueTask CloseAsync(long errorCode, CancellationToken cancellationToken=default(CancellationToken))
ValueTask WaitForAvailableBidirectionalStreamsAsync(CancellationToken cancellationToken=default(CancellationToken))
ValueTask ConnectAsync(CancellationToken cancellationToken=default(CancellationToken))
QuicConnection(QuicConnectionProvider provider)
ValueTask WaitForAvailableUnidirectionalStreamsAsync(CancellationToken cancellationToken=default(CancellationToken))
SslApplicationProtocol NegotiatedApplicationProtocol
async ValueTask< QuicStream > AcceptStreamAsync(CancellationToken cancellationToken=default(CancellationToken))