Show / Hide Table of Contents

Struct DelegatingReadOnlySpanConsumer<T, TArg>

Represents implementation of IReadOnlySpanConsumer<T> that delegates invocation to the delegate of type ReadOnlySpanAction<T, TArg>.

Implements
IReadOnlySpanConsumer<T>
ISupplier<ReadOnlyMemory<T>, CancellationToken, ValueTask>
IFunctional<Func<ReadOnlyMemory<T>, CancellationToken, ValueTask>>
Inherited Members
ValueType.Equals(object)
ValueType.GetHashCode()
ValueType.ToString()
object.Equals(object, object)
object.GetType()
object.ReferenceEquals(object, object)
Namespace: DotNext.Buffers
Assembly: DotNext.dll
Syntax
public readonly struct DelegatingReadOnlySpanConsumer<T, TArg> : IReadOnlySpanConsumer<T>, ISupplier<ReadOnlyMemory<T>, CancellationToken, ValueTask>, IFunctional<Func<ReadOnlyMemory<T>, CancellationToken, ValueTask>>
Type Parameters
Name Description
T

The type of the consumer argument.

TArg

The type of the argument to be passed to the delegate.

Constructors

| Edit this page View Source

DelegatingReadOnlySpanConsumer(ReadOnlySpanAction<T, TArg>, TArg)

Wraps the delegate instance.

Declaration
public DelegatingReadOnlySpanConsumer(ReadOnlySpanAction<T, TArg> action, TArg arg)
Parameters
Type Name Description
ReadOnlySpanAction<T, TArg> action

The delegate instance.

TArg arg

The argument to be passed to the function represented by the delegate.

Exceptions
Type Condition
ArgumentNullException

action is null.

Properties

| Edit this page View Source

IsEmpty

Gets a value indicating that the underlying delegate is null.

Declaration
public bool IsEmpty { get; }
Property Value
Type Description
bool

Implements

IReadOnlySpanConsumer<T>
ISupplier<T1, T2, TResult>
IFunctional<TDelegate>

Extension Methods

BasicExtensions.IsBetween<T, TLowerBound, TUpperBound>(T, TLowerBound, TUpperBound)
BasicExtensions.IsOneOf<T>(T, ReadOnlySpan<T>)
Collection.ToAsyncEnumerator<TEnumerator, T>(TEnumerator, CancellationToken)
Collection.ToClassicEnumerator<TEnumerator, T>(TEnumerator)
Enumerator.Skip<TEnumerator, T>(ref TEnumerator, int)
ExpressionBuilder.Const<T>(T)
  • Edit this page
  • View Source
☀
☾
In this article
Back to top
Supported by the .NET Foundation
☀
☾