Condividi tramite


IOutputChannelStore.OpenChannelAsync Method

Definition

Attaches a Stream to an existing channel for read access.

public:
 System::Threading::Tasks::ValueTask<Microsoft::VisualStudio::RpcContracts::OutputChannel::Channel ^> OpenChannelAsync(System::String ^ id, System::IO::Pipelines::PipeWriter ^ pipeWriter, System::Threading::CancellationToken cancellationToken);
public System.Threading.Tasks.ValueTask<Microsoft.VisualStudio.RpcContracts.OutputChannel.Channel> OpenChannelAsync (string id, System.IO.Pipelines.PipeWriter pipeWriter, System.Threading.CancellationToken cancellationToken);
abstract member OpenChannelAsync : string * System.IO.Pipelines.PipeWriter * System.Threading.CancellationToken -> System.Threading.Tasks.ValueTask<Microsoft.VisualStudio.RpcContracts.OutputChannel.Channel>
Public Function OpenChannelAsync (id As String, pipeWriter As PipeWriter, cancellationToken As CancellationToken) As ValueTask(Of Channel)

Parameters

id
String

A non-localized, unique string used to identify the existing channel. This may be a well-known ID or one obtained from GetChannelsAsync(CancellationToken).

pipeWriter
PipeWriter

The writer for the pipe that the store will use to send the channel data back to the caller.

cancellationToken
CancellationToken

A cancellation token.

Returns

An OutputChannel corresponding to the channel being opened.

Exceptions

Thrown when the channel id does not match any existing channel.

Applies to