Esempio n. 1
0
        /// <summary>
        ///    Assigns all <c>aSource</c> object's values to this instance of <see cref="CellFedCollection"/>.
        /// </summary>
        /// <param name="aSource">A source object.</param>
        public override void AssignFromSource(object aSource)
        {
            if (!(aSource is CellFedCollection))
            {
                throw new ArgumentException("Invalid assignment source", "CellFedCollection");
            }

            _isFiltered = (aSource as CellFedCollection)._isFiltered;
            _cellFedFilter = (aSource as CellFedCollection)._cellFedFilter;
            _cellFedList.Clear();
            foreach (CellFed vCellFedSource in (aSource as CellFedCollection)._cellFedList)
            {
                CellFed vCellFedTarget = new CellFed();
                vCellFedTarget.AssignFromSource(vCellFedSource);
                _cellFedList.Add(vCellFedTarget);
            }
        }
Esempio n. 2
0
        /// <summary>
        ///    Assigns all <c>aSource</c> object's values to this instance of <see cref="CellFedCollection"/>.
        /// </summary>
        /// <param name="aSource">A source object.</param>
        public override void AssignFromSource(object aSource)
        {
            if (!(aSource is CellFedCollection))
            {
                throw new ArgumentException("Invalid assignment source", "CellFedCollection");
            }

            _isFiltered    = (aSource as CellFedCollection)._isFiltered;
            _cellFedFilter = (aSource as CellFedCollection)._cellFedFilter;
            _cellFedList.Clear();
            foreach (CellFed vCellFedSource in (aSource as CellFedCollection)._cellFedList)
            {
                CellFed vCellFedTarget = new CellFed();
                vCellFedTarget.AssignFromSource(vCellFedSource);
                _cellFedList.Add(vCellFedTarget);
            }
        }