/// <summary> /// Indicates whether the current <see cref="GiftaidRecord" /> instance is equal to another <see cref="GiftaidRecord" /> instance. /// </summary> /// <param name="that"> /// The <see cref="GiftaidRecord" /> instance to be compared against this instance. /// </param> /// <returns> /// True if both instances are considered equal; otherwise, false. /// </returns> public Boolean Equals(GiftaidRecord that) { Boolean result = true; result = result && (this.Id == that.Id); result = result && (this.PnId.TrimOrNullify() == that.PnId.TrimOrNullify()); result = result && (this.Type.TrimOrNullify() == that.Type.TrimOrNullify()); result = result && (this.Active == that.Active); result = result && (this.StartDate == that.StartDate); result = result && (this.EndDate == that.EndDate); result = result && (this.Communication == that.Communication); result = result && (this.FirstName.TrimOrNullify() == that.FirstName.TrimOrNullify()); result = result && (this.Surname.TrimOrNullify() == that.Surname.TrimOrNullify()); return(result); }
/// <summary> /// Creates a new <see cref="GiftaidRecord" /> object instance that is a shallow-copy of the current object instance. /// </summary> /// <returns> /// The shallow-copy of the current <see cref="GiftaidRecord" /> object instance. /// </returns> public GiftaidRecord Clone() { GiftaidRecord record = new GiftaidRecord(); record.Id = this.Id; record.AddDate = this.AddDate; record.AddBy = this.AddBy; record.ModDate = this.ModDate; record.ModBy = this.ModBy; record.PnId = this.PnId; record.Type = this.Type; record.Active = this.Active; record.StartDate = this.StartDate; record.EndDate = this.EndDate; record.Communication = this.Communication; record.FirstName = this.FirstName; record.Surname = this.Surname; return(record); }