Szerkesztés

Megosztás a következőn keresztül:


QuicConnection.OpenOutboundStreamAsync Method

Definition

Creates an outbound unidirectional or bidirectional QuicStream.

public System.Threading.Tasks.ValueTask<System.Net.Quic.QuicStream> OpenOutboundStreamAsync (System.Net.Quic.QuicStreamType type, System.Threading.CancellationToken cancellationToken = default);
member this.OpenOutboundStreamAsync : System.Net.Quic.QuicStreamType * System.Threading.CancellationToken -> System.Threading.Tasks.ValueTask<System.Net.Quic.QuicStream>
Public Function OpenOutboundStreamAsync (type As QuicStreamType, Optional cancellationToken As CancellationToken = Nothing) As ValueTask(Of QuicStream)

Parameters

type
QuicStreamType

The type of the stream, either unidirectional or bidirectional.

cancellationToken
CancellationToken

A cancellation token that can be used to cancel the asynchronous operation.

Returns

An asynchronous task that completes with the opened QuicStream.

Exceptions

The cancellation token was canceled. This exception is stored into the returned task.

Remarks

If the connection doesn't have any available stream capacity, that is, the peer limits the concurrent stream count, the operation pends until the peer increases the stream limit.

Applies to