Ejemplo n.º 1
0
		public virtual void CopyFrom(Person other)
		{
			HomeAddressCol.Clear();
			foreach (Address otherItem in other.HomeAddressCol)
				HomeAddressCol.Add(otherItem == null ? null : new Address(otherItem));
			WorkAddressCol.Clear();
			WorkAddressCol.AddRange(other.WorkAddressCol);
			if (other.lazyAddressCol != null)
			{
				LazyAddressCol.Clear();
				foreach (Address otherItem in other.LazyAddressCol)
					LazyAddressCol.Add(otherItem == null ? null : new Address(otherItem));
			}
			else
			{
				if (this.lazyAddressCol != null)
					this.lazyAddressCol.Clear();
			}
			StringCol.Clear();
			foreach (string otherItem in other.StringCol)
				StringCol.Add(otherItem == null ? null : string.Copy(otherItem));
			StringCol2.Clear();
			StringCol2.AddRange(other.StringCol2);
			DoubleCol.Clear();
			DoubleCol.AddRange(other.DoubleCol);
			DoubleCol2.Clear();
			DoubleCol2.AddRange(other.DoubleCol2);
			if (other.HomeAddressProp == null)
				HomeAddressProp = null;
			else
				HomeAddressProp = new Address(other.HomeAddressProp);
			WorkAddressProp = other.WorkAddressProp;
		}
Ejemplo n.º 2
0
		public Person(Person other)
		: base(other)
		{
		}