Skip to content

ArrayEnumerator<TItem>

Definition

Namespace: Corvus.Text.Json
Assembly: Corvus.Text.Json.dll
Source: ArrayEnumerator.cs

Provides an enumerator and enumerable for iterating over the elements of a JSON array in a document.

public readonly struct ArrayEnumerator<TItem> : IEnumerable<TItem>, IEnumerable, IEnumerator<TItem>, IEnumerator, IDisposable
    where TItem : struct, IJsonElement<TItem>

Type Parameters

Parameter Description
TItem The type of the JSON element to enumerate, which must implement IJsonElement.

Implements

IEnumerable<TItem>, IEnumerable, IEnumerator<TItem>, IEnumerator, IDisposable

Properties

Property Type Description
Current TItem Gets the current element in the collection.

Methods

Method Description
Dispose() Releases resources used by the enumerator.
GetEnumerator() Returns an enumerator that iterates through the JSON array.
MoveNext() Advances the enumerator to the next element of the collection.
Reset() Sets the enumerator to its initial position, which is before the first element in the collection.

Applies To

Product Versions
.NET 9, 10
.NET Standard 2.0, 2.1

Collaborate with us on GitHub

The source for this content can be found on GitHub, where you can also create and review issues and pull requests.

Open an issue