Elin Decompiled Documentation EA 23.102 Nightly
Loading...
Searching...
No Matches
ExcelDataListExtension.cs
Go to the documentation of this file.
1using System.Collections.Generic;
2
3public static class ExcelDataListExtension
4{
5 public static int IndexOf(this List<Dictionary<string, string>> list, string id)
6 {
7 for (int i = 0; i < list.Count; i++)
8 {
9 if (list[i]["id"] == id)
10 {
11 return i;
12 }
13 }
14 return -1;
15 }
16
17 public static string GetNextID(this List<Dictionary<string, string>> list, string currentId, int a)
18 {
19 int num = list.IndexOf(currentId) + a;
20 if (num >= list.Count)
21 {
22 num = 0;
23 }
24 if (num < 0)
25 {
26 num = list.Count - 1;
27 }
28 return list[num]["id"];
29 }
30}
static int IndexOf(this List< Dictionary< string, string > > list, string id)
static string GetNextID(this List< Dictionary< string, string > > list, string currentId, int a)