DotNext by .NET Foundation and Contributors

<PackageReference Include="DotNext" Version="5.8.0" />

 SingletonList<T>

Represents a list with one element.

Represents an enumerator over the collection containing a single element.

public T Item

The item of the list.

public T this[int index] { get; set; }

Gets or sets the item in this list.

public static SingletonList<T> op_Implicit(T item)

Converts a value to the read-only list.

Gets enumerator for the single element in the list.