Skip to Main Content

BTD_Mod_Helper​.Extensions​.Il2CppGenerics


BloonsTD6 Mod Helper

BTD_Mod_Helper.Extensions

Il2CppGenerics Class

Extensions for il2cpp lists

public static class Il2CppGenerics

Inheritance System.Object  Il2CppGenerics

Methods

Il2CppGenerics.Any(this List, Func<T,bool>) Method

Return whether or not there are any elements in this that match the predicate

public static bool Any<T>(this List<T> source, System.Func<T,bool> predicate)
    where T : Il2CppObjectBase;

Type parameters

T

Parameters

source Il2CppSystem.Collections.Generic.List

predicate System.Func<T,System.Boolean>

Returns

System.Boolean

Il2CppGenerics.Any(this List) Method

Return whether or not there are any elements in this

public static bool Any<T>(this List<T> source)
    where T : Object;

Type parameters

T

Parameters

source Il2CppSystem.Collections.Generic.List

Returns

System.Boolean

Il2CppGenerics.FindIndex(this List, Func<T,bool>) Method

Return the index of the element that matches the predicate

public static int FindIndex<T>(this List<T> source, System.Func<T,bool> predicate)
    where T : Il2CppObjectBase;

Type parameters

T

Parameters

source Il2CppSystem.Collections.Generic.List

predicate System.Func<T,System.Boolean>

Returns

System.Int32

Il2CppGenerics.First(this List, Func<T,bool>) Method

Return the first element that matches the predicate

public static T First<T>(this List<T> source, System.Func<T,bool> predicate)
    where T : Il2CppObjectBase;

Type parameters

T

Parameters

source Il2CppSystem.Collections.Generic.List

predicate System.Func<T,System.Boolean>

Returns

T

Il2CppGenerics.First(this List) Method

Return the first element in the collection

public static T First<T>(this List<T> source);

Type parameters

T

Parameters

source Il2CppSystem.Collections.Generic.List

Returns

T

Il2CppGenerics.FirstOrDefault(this List, Func<T,bool>) Method

Return the first element that matches the predicate, or return default

public static T FirstOrDefault<T>(this List<T> source, System.Func<T,bool> predicate)
    where T : Il2CppObjectBase;

Type parameters

T

Parameters

source Il2CppSystem.Collections.Generic.List

predicate System.Func<T,System.Boolean>

Returns

T

Il2CppGenerics.FirstOrDefault(this List) Method

Return the first element in the collection, or return default if it's null

public static T FirstOrDefault<T>(this List<T> source);

Type parameters

T

Parameters

source Il2CppSystem.Collections.Generic.List

Returns

T

Il2CppGenerics.Last(this List) Method

Return the last item in the collection

public static T Last<T>(this List<T> source);

Type parameters

T

Parameters

source Il2CppSystem.Collections.Generic.List

Returns

T

Il2CppGenerics.LastOrDefault(this List, Func<T,bool>) Method

Return the last item in the collection that meets the condition, or return default

public static T LastOrDefault<T>(this List<T> source, System.Func<T,bool> predicate);

Type parameters

T

Parameters

source Il2CppSystem.Collections.Generic.List

predicate System.Func<T,System.Boolean>

Returns

T

Il2CppGenerics.Where(this List, Func<T,bool>) Method

Return all elements that match the predicate

public static List<T> Where<T>(this List<T> source, System.Func<T,bool> predicate)
    where T : Il2CppObjectBase;

Type parameters

T

Parameters

source Il2CppSystem.Collections.Generic.List

predicate System.Func<T,System.Boolean>

Returns

Il2CppSystem.Collections.Generic.List

To learn how to download BTD Mod Helper and install mods, click here