System.Collections.Immutable by Microsoft

<PackageReference Include="System.Collections.Immutable" Version="1.6.0-preview3.19128.7" />

.NET API 175,184 bytes

 ImmutableQueue<T>

public sealed class ImmutableQueue<T> : IImmutableQueue<T>, IEnumerable<T>, IEnumerable
Represents an immutable queue. NuGet package: System.Collections.Immutable (about immutable collections and how to install)
public struct Enumerator<T>

Enumerates the contents of an immutable queue without allocating any memory. NuGet package: System.Collections.Immutable (about immutable collections and how to install)

public static ImmutableQueue<T> Empty { get; }

Gets an empty immutable queue.

public bool IsEmpty { get; }

Gets a value that indicates whether this immutable queue is empty. NuGet package: System.Collections.Immutable (about immutable collections and how to install)

public ImmutableQueue<T> Clear()

Removes all objects from the immutable queue.

public ImmutableQueue<T> Dequeue()

Removes the element at the beginning of the immutable queue, and returns the new queue.

public ImmutableQueue<T> Dequeue(out T value)

Removes the item at the beginning of the immutable queue, and returns the new queue.

public ImmutableQueue<T> Enqueue(T value)

Adds an element to the end of the immutable queue, and returns the new queue.

Returns an enumerator that iterates through the immutable queue.

public T Peek()

Returns the element at the beginning of the immutable queue without removing it.