/// <summary> This method copy's each database field from the <paramref name="source"/> interface to this data row.</summary> public void Copy_From(IRingMetaData source, bool includePrimaryKey = false) { if (includePrimaryKey) this.Id = source.Id; this.SenderId = source.SenderId; this.CreationDate = source.CreationDate; this.TargetDate = source.TargetDate; this.Occasion = source.Occasion; }
/// <summary> /// This method copy's each database field which is in the <paramref name="includedColumns"/> /// from the <paramref name="source"/> interface to this data row. /// </summary> public void Copy_From_But_TakeOnly(IRingMetaData source, params string[] includedColumns) { if (includedColumns.Contains(RingMetaDatasTable.IdCol)) this.Id = source.Id; if (includedColumns.Contains(RingMetaDatasTable.SenderIdCol)) this.SenderId = source.SenderId; if (includedColumns.Contains(RingMetaDatasTable.CreationDateCol)) this.CreationDate = source.CreationDate; if (includedColumns.Contains(RingMetaDatasTable.TargetDateCol)) this.TargetDate = source.TargetDate; if (includedColumns.Contains(RingMetaDatasTable.OccasionCol)) this.Occasion = source.Occasion; }
/// <summary> This method copy's each database field into the <paramref name="target"/> interface. </summary> public void Copy_To(IRingMetaData target, bool includePrimaryKey = false) { if (includePrimaryKey) target.Id = this.Id; target.SenderId = this.SenderId; target.CreationDate = this.CreationDate; target.TargetDate = this.TargetDate; target.Occasion = this.Occasion; }