Show / Hide Table of Contents

Struct ReadOnlyListEnumerator<T>

A structure similar to ListEnumerator<T>, but for IReadOnlyList<T>. It is not quite as fast as ListEnumerator<T>, but is still faster than using the typical Enumerable implementation for IReadOnlyList. You should only use this if you can't use ListEnumerator<T> due to the type you're working with; they share the same characteristics otherwise.

Implements
IEnumerator<T>
IEnumerator
IDisposable
IEnumerable<T>
IEnumerable
Inherited Members
ValueType.Equals(object)
ValueType.GetHashCode()
ValueType.ToString()
object.GetType()
object.Equals(object, object)
object.ReferenceEquals(object, object)
Namespace: SadRogue.Primitives
Assembly: TheSadRogue.Primitives.dll
Syntax
public struct ReadOnlyListEnumerator<T> : IEnumerator<T>, IEnumerator, IDisposable, IEnumerable<T>, IEnumerable
Type Parameters
Name Description
T

Types of elements stored in the list.

Constructors

View Source

ReadOnlyListEnumerator(IReadOnlyList<T>)

Constructor.

Declaration
public ReadOnlyListEnumerator(IReadOnlyList<T> list)
Parameters
Type Name Description
IReadOnlyList<T> list

List to iterate over.

Properties

View Source

Current

Declaration
public T Current { get; }
Property Value
Type Description
T

Methods

View Source

Dispose()

Declaration
public void Dispose()
View Source

GetEnumerator()

Returns this enumerator.

Declaration
public ReadOnlyListEnumerator<T> GetEnumerator()
Returns
Type Description
ReadOnlyListEnumerator<T>

This enumerator.

View Source

MoveNext()

Declaration
public bool MoveNext()
Returns
Type Description
bool

Implements

IEnumerator<T>
IEnumerator
IDisposable
IEnumerable<T>
IEnumerable

Extension Methods

PropertyChangedEventHelpers.SafelySetProperty<TObject, TProperty>(TObject, ref TProperty, TProperty, EventHandler<ValueChangedEventArgs<TProperty>>?)
PropertyChangedEventHelpers.SafelySetProperty<TObject, TProperty>(TObject, ref TProperty, TProperty, EventHandler<ValueChangedEventArgs<TProperty>>?, EventHandler<ValueChangedEventArgs<TProperty>>?)
ToStringExtensions.ExtendToString<T>(IEnumerable<T>, string, Func<T, string>?, string, string)
  • View Source
In this article
Back to top Generated by DocFX