コード例 #1
0
        internal SLGroupItems Clone()
        {
            SLGroupItems gis = new SLGroupItems();

            gis.Items = new List<SLSharedGroupItemsTypeIndexPair>();
            foreach (SLSharedGroupItemsTypeIndexPair pair in this.Items)
            {
                gis.Items.Add(new SLSharedGroupItemsTypeIndexPair(pair.Type, pair.Index));
            }

            gis.MissingItems = new List<SLMissingItem>();
            foreach (SLMissingItem mi in this.MissingItems)
            {
                gis.MissingItems.Add(mi.Clone());
            }

            gis.NumberItems = new List<SLNumberItem>();
            foreach (SLNumberItem ni in this.NumberItems)
            {
                gis.NumberItems.Add(ni.Clone());
            }

            gis.BooleanItems = new List<SLBooleanItem>();
            foreach (SLBooleanItem bi in this.BooleanItems)
            {
                gis.BooleanItems.Add(bi.Clone());
            }

            gis.ErrorItems = new List<SLErrorItem>();
            foreach (SLErrorItem ei in this.ErrorItems)
            {
                gis.ErrorItems.Add(ei.Clone());
            }

            gis.StringItems = new List<SLStringItem>();
            foreach (SLStringItem si in this.StringItems)
            {
                gis.StringItems.Add(si.Clone());
            }

            gis.DateTimeItems = new List<SLDateTimeItem>();
            foreach (SLDateTimeItem dti in this.DateTimeItems)
            {
                gis.DateTimeItems.Add(dti.Clone());
            }

            return gis;
        }
コード例 #2
0
ファイル: SLGroupItems.cs プロジェクト: nunezger/berkeleyshoe
        internal SLGroupItems Clone()
        {
            SLGroupItems gis = new SLGroupItems();

            gis.Items = new List <SLSharedGroupItemsTypeIndexPair>();
            foreach (SLSharedGroupItemsTypeIndexPair pair in this.Items)
            {
                gis.Items.Add(new SLSharedGroupItemsTypeIndexPair(pair.Type, pair.Index));
            }

            gis.MissingItems = new List <SLMissingItem>();
            foreach (SLMissingItem mi in this.MissingItems)
            {
                gis.MissingItems.Add(mi.Clone());
            }

            gis.NumberItems = new List <SLNumberItem>();
            foreach (SLNumberItem ni in this.NumberItems)
            {
                gis.NumberItems.Add(ni.Clone());
            }

            gis.BooleanItems = new List <SLBooleanItem>();
            foreach (SLBooleanItem bi in this.BooleanItems)
            {
                gis.BooleanItems.Add(bi.Clone());
            }

            gis.ErrorItems = new List <SLErrorItem>();
            foreach (SLErrorItem ei in this.ErrorItems)
            {
                gis.ErrorItems.Add(ei.Clone());
            }

            gis.StringItems = new List <SLStringItem>();
            foreach (SLStringItem si in this.StringItems)
            {
                gis.StringItems.Add(si.Clone());
            }

            gis.DateTimeItems = new List <SLDateTimeItem>();
            foreach (SLDateTimeItem dti in this.DateTimeItems)
            {
                gis.DateTimeItems.Add(dti.Clone());
            }

            return(gis);
        }