/// <summary> /// Not tested /// </summary> public static SizedList <T> ToSizedList <T>(this List <T> il2CppList) { SizedList <T> sizedList = new SizedList <T>(); foreach (T item in il2CppList) { sizedList.Add(item); } return(sizedList); }
/// <summary> /// Not tested /// </summary> public static SizedList <T> ToSizedList <T>(this Il2CppReferenceArray <T> referenceArray) where T : Il2CppSystem.Object { SizedList <T> sizedList = new SizedList <T>(); foreach (T item in referenceArray) { sizedList.Add(item); } return(sizedList); }
public static SizedList <T> Duplicate <T>(this SizedList <T> list) { SizedList <T> newList = new SizedList <T>(); for (int i = 0; i < list.count; i++) { newList.Add(list[i]); } return(newList); }
/// <summary> /// Not Tested /// </summary> public static SizedList <T> ToSizedList <T>(this T[] array) { SizedList <T> sizedList = new SizedList <T>(); foreach (T item in array) { sizedList.Add(item); } return(sizedList); }
/// <summary> /// Not Tested /// </summary> public static SizedList <T> ToSizedList <T>(this LockList <T> lockList) { SizedList <T> sizedList = new SizedList <T>(); for (int i = 0; i < sizedList.Count; i++) { sizedList.Add(sizedList[i]); } return(sizedList); }
public static SizedList <TCast> DuplicateAs <TSource, TCast>(this SizedList <TSource> list) where TSource : Il2CppSystem.Object where TCast : Il2CppSystem.Object { SizedList <TCast> newList = new SizedList <TCast>(); for (int i = 0; i < list.count; i++) { newList.Add(list[i].TryCast <TCast>()); } return(newList); }