Esempio n. 1
0
        public void add(string key, object callback, object orgs)
        {
            ArrayList list = MapEx.getList(delegateInfro, key);

            if (list == null)
            {
                list = ObjPool.listPool.borrowObject();
            }
            NewList infor = ObjPool.listPool.borrowObject();

            infor.Add(callback);
            infor.Add(orgs);
            list.Add(infor);
            delegateInfro [key] = list;
        }
Esempio n. 2
0
        public void remove(string key, object callback)
        {
            ArrayList list = MapEx.getList(delegateInfro, key);

            if (list == null)
            {
                return;
            }

            NewList cell = null;

            while (list.Count > 0)
            {
                cell = (list[list.Count - 1]) as NewList;
                if (cell[0] == null || cell[0].Equals(callback))
                {
                    ObjPool.listPool.returnObject(cell);
                    list.RemoveAt(list.Count - 1);
                }
            }
        }
Esempio n. 3
0
 public ArrayList getDelegates(string key)
 {
     return(MapEx.getList(delegateInfro, key));
 }