IOutputChannelStore.CreateChannelAsync Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Creates a new output channel and supplies the Stream used to write to it.
public:
System::Threading::Tasks::Task ^ CreateChannelAsync(System::String ^ id, System::String ^ displayNameResourceId, System::IO::Pipelines::PipeReader ^ pipeReader, System::Text::Encoding ^ encoding, System::Threading::CancellationToken cancellationToken);
public System.Threading.Tasks.Task CreateChannelAsync (string id, string displayNameResourceId, System.IO.Pipelines.PipeReader pipeReader, System.Text.Encoding encoding, System.Threading.CancellationToken cancellationToken);
abstract member CreateChannelAsync : string * string * System.IO.Pipelines.PipeReader * System.Text.Encoding * System.Threading.CancellationToken -> System.Threading.Tasks.Task
Public Function CreateChannelAsync (id As String, displayNameResourceId As String, pipeReader As PipeReader, encoding As Encoding, cancellationToken As CancellationToken) As Task
Parameters
- id
- String
A non-localized, unique string used to identify the created channel.
- displayNameResourceId
- String
The ID of the resource that should be used as the DisplayName for this channel. This ID will be exchanged for the actual DisplayName value by calling back to the client via the IStringResourceDictionary interface.
- pipeReader
- PipeReader
The reader for the pipe that the store will use to receive data from the channel. When the writer of the pipe is completed, the channel will close.
- encoding
- Encoding
The WebName from the Encoding the caller will use for encoding characters over the pipeReader
.
- cancellationToken
- CancellationToken
A cancellation token.
Returns
A task that represents the completion of creating the channel.
Exceptions
Thrown when id
conflicts with an open channel.