Esempio n. 1
0
 public static void Each <T>(IList <T> list, EachDelegate <T> each)
 {
     foreach (T element in list)
     {
         each(element);
     }
 }
Esempio n. 2
0
 public void Each(EachDelegate <T> func)
 {
     for (int i = 0; i < this.list.Count; i++)
     {
         func(this.list[i]);
         aaa();
     }
 }
Esempio n. 3
0
        public List <int> each(EachDelegate MyDelegate)
        {
            List <int> res = new List <int>();

            foreach (int item in _myList)
            {
                if (MyDelegate(item))
                {
                    res.Add(item);
                }
            }

            return(res);
        }