Skip to Main Content

BTD_Mod_Helper​.Api​.Helpers​.Il2CppEnumerator_T_


BloonsTD6 Mod Helper

BTD_Mod_Helper.Api.Helpers

Il2CppEnumerator Class

Wrapper for il2cpp enumerator so that it actually extends the normal System enumerator

public class Il2CppEnumerator<T> :
System.Collections.Generic.IEnumerator<T>,
System.Collections.IEnumerator,
System.IDisposable

Type parameters

T

Inheritance System.Object  Il2CppEnumerator

Implements System.Collections.Generic.IEnumerator<T>, System.Collections.IEnumerator, System.IDisposable

Constructors

Il2CppEnumerator(IEnumerable) Constructor

Construction a wrapper for an il2cpp enumerator

public Il2CppEnumerator(IEnumerable<T> enumerable);

Parameters

enumerable Il2CppSystem.Collections.Generic.IEnumerable

Il2CppEnumerator(IEnumerator) Constructor

Construction a wrapper for an il2cpp enumerator

public Il2CppEnumerator(IEnumerator<T> enumerator);

Parameters

enumerator Il2CppSystem.Collections.Generic.IEnumerator

Properties

Il2CppEnumerator.Current Property

Gets the element in the collection at the current position of the enumerator.

public T Current { get; }

Implements Current, Current

Property Value

T

Il2CppEnumerator.Enumerator Property

The internal il2cpp enumerator being wrapped

public IEnumerator<T> Enumerator { get; }

Property Value

Il2CppSystem.Collections.Generic.IEnumerator

Methods

Il2CppEnumerator.Dispose() Method

Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.

public void Dispose();

Implements Dispose()

Il2CppEnumerator.MoveNext() Method

Advances the enumerator to the next element of the collection.

public bool MoveNext();

Implements MoveNext()

Returns

System.Boolean
true if the enumerator was successfully advanced to the next element; false if the enumerator has passed the end of the collection.

Exceptions

System.InvalidOperationException
The collection was modified after the enumerator was created.

Il2CppEnumerator.Reset() Method

Sets the enumerator to its initial position, which is before the first element in the collection.

public void Reset();

Implements Reset()

Exceptions

System.InvalidOperationException
The collection was modified after the enumerator was created.

Operators

Il2CppEnumerator.implicit operator Il2CppEnumerator(IEnumerable) Operator

Wraps an il2cpp enumerable

public static BTD_Mod_Helper.Api.Helpers.Il2CppEnumerator<T> implicit operator Il2CppEnumerator<T>(IEnumerable<T> enumerator);

Parameters

enumerator Il2CppSystem.Collections.Generic.IEnumerable

Returns

BTD_Mod_Helper.Api.Helpers.Il2CppEnumerator<T>

Il2CppEnumerator.implicit operator Il2CppEnumerator(IEnumerator) Operator

Wraps an il2cpp enumerator

public static BTD_Mod_Helper.Api.Helpers.Il2CppEnumerator<T> implicit operator Il2CppEnumerator<T>(IEnumerator<T> enumerator);

Parameters

enumerator Il2CppSystem.Collections.Generic.IEnumerator

Returns

BTD_Mod_Helper.Api.Helpers.Il2CppEnumerator<T>

Explicit Interface Implementations

Il2CppEnumerator.System.Collections.IEnumerator.Current Property

Gets the current element in the collection.

object System.Collections.IEnumerator.Current { get; }

Implements Current