/// <summary> /// Replicates the properties from this object /// to the specified <paramref name="attribute"/> object. /// </summary> /// <param name="attribute"></param> protected internal override void CopyDeltaTo(DataModelMappingAttributeBase attribute) { var obj = (ForeignDataModelAttribute)attribute; obj.LocalColumn = this.LocalColumn; if (this._LocalColumnDbType.HasValue) { obj.LocalColumnDbType = this.LocalColumnDbType; } if (this._LocalColumnSqlDbType.HasValue) { obj.LocalColumnSqlDbType = this.LocalColumnSqlDbType; } if (this._LocalColumnSize.HasValue) { obj.LocalColumnSize = this.LocalColumnSize; } if (this._LocalColumnIsNullable.HasValue) { obj.LocalColumnIsNullable = this.LocalColumnIsNullable; } obj.RelatedTableColumn = this.RelatedTableColumn; obj.RelatedTableSchema = this.RelatedTableSchema; obj.RelatedTable = this.RelatedTable; obj.MappingTable = this.MappingTable; obj.MappingTableSchema = this.MappingTableSchema; obj.Relationship = this.Relationship; }
/// <summary> /// Replicates the properties from this object /// to the specified <see cref="DataModelMappingAttributeBase"/> object. /// </summary> /// <param name="dattribute"></param> protected internal override void CopyDeltaTo(DataModelMappingAttributeBase dattribute) { var attribute = (DataModelTableMappingAttribute)dattribute; if (!string.IsNullOrEmpty(this.Schema)) { attribute.Schema = this.Schema; } if (!string.IsNullOrEmpty(this.Table)) { attribute.Table = this.Table; } }
/// <summary> /// Replicates the properties from this object /// to the specified <paramref name="attribute"/> object. /// </summary> /// <param name="attribute"></param> protected internal override void CopyDeltaTo(DataModelMappingAttributeBase attribute) { var attr = attribute as DataModelForeignKeyAttribute; if (attr != null) { attr.ForeignEntity = this.ForeignEntity; attr.ForeignSchemaName = this.ForeignSchemaName; attr.ForeignTableName = this.ForeignTableName; attr.ForeignColumn = this.ForeignColumn; attr.ForeignProperty = this.ForeignProperty; attr.Relationship = this.Relationship; attr.AssignToMember = this.AssignToMember; } }
/// <summary> /// Replicates the properties from this object /// to the specified <paramref name="attribute"/> object. /// </summary> /// <param name="attribute"></param> protected internal override void CopyDeltaTo(DataModelMappingAttributeBase attribute) { var attr = attribute as DataModelFieldMappingAttribute; if (attr != null) { attr.ClearBaseObjectMapping = this.ClearBaseObjectMapping; attr._DbType = this._DbType; attr._SqlDbType = this._SqlDbType; attr._DataType = this._DataType; attr._DefaultValue = this._DefaultValue; attr.ColumnName = this.ColumnName; attr.ForeignKeyMapping = this.ForeignKeyMapping; attr._IsIdentity = this._IsIdentity; attr._IsPrimaryKey = this._IsPrimaryKey; attr.TargetMember = this.TargetMember; attr.TargetMemberType = this.TargetMemberType; } }
/// <summary> /// When implemented, replicates the properties from this object /// to the specified <paramref name="attribute"/> object. /// </summary> /// <param name="attribute"></param> protected internal abstract void CopyDeltaTo(DataModelMappingAttributeBase attribute);