Show / Hide Table of Contents

Struct ReadOnlySpanConsumer<T, TArg>

Represents typed function pointer implementing IReadOnlySpanConsumer<T>.

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
[CLSCompliant(false)]
public readonly struct ReadOnlySpanConsumer<T, TArg> : IReadOnlySpanConsumer<T>, ISupplier<ReadOnlyMemory<T>, CancellationToken, ValueTask>, IFunctional<Func<ReadOnlyMemory<T>, CancellationToken, ValueTask>>
Type Parameters
Name Description
T

The type of the elements in the span.

TArg

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

Remarks

This type follows signature of ReadOnlySpanAction<T, TArg> delegate.

Constructors

| Edit this page View Source

ReadOnlySpanConsumer(delegate*<ReadOnlySpan<T>, TArg, void>, TArg)

Wraps the function pointer and captures the argument.

Declaration
public ReadOnlySpanConsumer(delegate*<ReadOnlySpan<T>, TArg, void> ptr, TArg arg)
Parameters
Type Name Description
delegate*<ReadOnlySpan<T>, TArg, void> ptr

The function pointer.

TArg arg

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

Exceptions
Type Condition
ArgumentNullException

ptr is zero.

Properties

| Edit this page View Source

IsEmpty

Gets a value indicating that this function pointer is zero.

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
☀
☾