Table of Contents

Class NotSupportedChannelReader

Namespace
Steeltoe.Messaging.Support
Assembly
Steeltoe.Messaging.MessagingBase.dll
public class NotSupportedChannelReader : ChannelReader<IMessage>
Inheritance
NotSupportedChannelReader
Inherited Members

Properties

Completion

Gets a Task that completes when no more data will ever be available to be read from this channel.

public override Task Completion { get; }

Property Value

Task

Methods

ReadAllAsync(CancellationToken)

Creates an IAsyncEnumerable<T> that enables reading all of the data from the channel.

public override IAsyncEnumerable<IMessage> ReadAllAsync(CancellationToken cancellationToken = default)

Parameters

cancellationToken CancellationToken

The cancellation token to use to cancel the enumeration.

Returns

IAsyncEnumerable<IMessage>

The created async enumerable.

ReadAsync(CancellationToken)

Asynchronously reads an item from the channel.

public override ValueTask<IMessage> ReadAsync(CancellationToken cancellationToken = default)

Parameters

cancellationToken CancellationToken

A CancellationToken used to cancel the read operation.

Returns

ValueTask<IMessage>

A ValueTask<TResult> that represents the asynchronous read operation.

TryRead(out IMessage)

Attempts to read an item from the channel.

public override bool TryRead(out IMessage item)

Parameters

item IMessage

The read item, or a default value if no item could be read.

Returns

bool

true if an item was read; otherwise, false.

WaitToReadAsync(CancellationToken)

Returns a ValueTask<TResult> that will complete when data is available to read.

public override ValueTask<bool> WaitToReadAsync(CancellationToken cancellationToken = default)

Parameters

cancellationToken CancellationToken

A CancellationToken used to cancel the wait operation.

Returns

ValueTask<bool>

A ValueTask<TResult> that will complete with a true result when data is available to read or with a false result when no further data will ever be available to be read due to the channel completing successfully. If the channel completes with an exception, the task will also complete with an exception. .