/// <summary> This method copy's each database field from the <paramref name="source"/> interface to this data row.</summary> public void Copy_From(IMMElement source, bool includePrimaryKey = false) { if (includePrimaryKey) this.Id = source.Id; this.NameId = source.NameId; this.TextId = source.TextId; this.SortOrder = source.SortOrder; this.TypId = source.TypId; this.MMUnitId = source.MMUnitId; this.LocalText = source.LocalText; this.ForeignElementId = source.ForeignElementId; this.ForeignElementTypId = source.ForeignElementTypId; this.PictureId = source.PictureId; this.VideoId = source.VideoId; this.HashCode = source.HashCode; this.ValueFileReference = source.ValueFileReference; this.LastWriteTimeForFileReference = source.LastWriteTimeForFileReference; this.ValueThumb = source.ValueThumb; this.ModifyTimeStamp = source.ModifyTimeStamp; this.LastUpdateToken = source.LastUpdateToken; }
/// <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(IMMElement source, params string[] includedColumns) { if (includedColumns.Contains(MMElementeTable.IdCol)) this.Id = source.Id; if (includedColumns.Contains(MMElementeTable.NameIdCol)) this.NameId = source.NameId; if (includedColumns.Contains(MMElementeTable.TextIdCol)) this.TextId = source.TextId; if (includedColumns.Contains(MMElementeTable.SortOrderCol)) this.SortOrder = source.SortOrder; if (includedColumns.Contains(MMElementeTable.TypIdCol)) this.TypId = source.TypId; if (includedColumns.Contains(MMElementeTable.MMUnitIdCol)) this.MMUnitId = source.MMUnitId; if (includedColumns.Contains(MMElementeTable.LocalTextCol)) this.LocalText = source.LocalText; if (includedColumns.Contains(MMElementeTable.ForeignElementIdCol)) this.ForeignElementId = source.ForeignElementId; if (includedColumns.Contains(MMElementeTable.ForeignElementTypIdCol)) this.ForeignElementTypId = source.ForeignElementTypId; if (includedColumns.Contains(MMElementeTable.PictureIdCol)) this.PictureId = source.PictureId; if (includedColumns.Contains(MMElementeTable.VideoIdCol)) this.VideoId = source.VideoId; if (includedColumns.Contains(MMElementeTable.HashCodeCol)) this.HashCode = source.HashCode; if (includedColumns.Contains(MMElementeTable.ValueFileReferenceCol)) this.ValueFileReference = source.ValueFileReference; if (includedColumns.Contains(MMElementeTable.LastWriteTimeForFileReferenceCol)) this.LastWriteTimeForFileReference = source.LastWriteTimeForFileReference; if (includedColumns.Contains(MMElementeTable.ValueThumbCol)) this.ValueThumb = source.ValueThumb; if (includedColumns.Contains(MMElementeTable.ModifyTimeStampCol)) this.ModifyTimeStamp = source.ModifyTimeStamp; if (includedColumns.Contains(MMElementeTable.LastUpdateTokenCol)) this.LastUpdateToken = source.LastUpdateToken; }
/// <summary> This method copy's each database field into the <paramref name="target"/> interface. </summary> public void Copy_To(IMMElement target, bool includePrimaryKey = false) { if (includePrimaryKey) target.Id = this.Id; target.NameId = this.NameId; target.TextId = this.TextId; target.SortOrder = this.SortOrder; target.TypId = this.TypId; target.MMUnitId = this.MMUnitId; target.LocalText = this.LocalText; target.ForeignElementId = this.ForeignElementId; target.ForeignElementTypId = this.ForeignElementTypId; target.PictureId = this.PictureId; target.VideoId = this.VideoId; target.HashCode = this.HashCode; target.ValueFileReference = this.ValueFileReference; target.LastWriteTimeForFileReference = this.LastWriteTimeForFileReference; target.ValueThumb = this.ValueThumb; target.ModifyTimeStamp = this.ModifyTimeStamp; target.LastUpdateToken = this.LastUpdateToken; }