Пример #1
0
        public CColumnInView FindByColumn(Guid FW_Column_id)
        {
            List <CBaseObject> lstObj = GetList();

            foreach (CBaseObject obj in lstObj)
            {
                CColumnInView civ = (CColumnInView)obj;
                if (civ.FW_Column_id == FW_Column_id)
                {
                    return(civ);
                }
            }
            return(null);
        }
Пример #2
0
        public int NewIdx()
        {
            int iNexIdx = -1;
            List <CBaseObject> lstObj = GetList();

            foreach (CBaseObject obj in lstObj)
            {
                CColumnInView civ = (CColumnInView)obj;
                if (civ.Idx > iNexIdx)
                {
                    iNexIdx = civ.Idx;
                }
            }
            return(iNexIdx + 1);
        }
Пример #3
0
        public int CompareTo(object obj)
        {
            int res = 0;

            try
            {
                CColumnInView sObj = (CColumnInView)obj;
                if (this.Idx > sObj.Idx)
                {
                    res = 1;
                }
                else if (this.Idx < sObj.Idx)
                {
                    res = -1;
                }
            }
            catch (Exception ex)
            {
                throw new Exception("比较异常", ex.InnerException);
            }
            return(res);
        }