From 956f9eefc0cdd783231818bede7d7c7c7b4ab855 Mon Sep 17 00:00:00 2001 From: vmelamed Date: Fri, 25 Dec 2015 18:14:10 -0500 Subject: [PATCH] Released 1.0.12=beta: * Changed the visibility of the field _id in the classes vm.Aspects.Model.DomainEntity and vm.Aspects.Model.DomainValue from private to protected. This will allow the inheritors to modify the behavior of the property Id, without unnecessary duplicating the backing field. * The property Id was applied the attributes KeyAttribute and ColumnAttribute with argument Order=0. * Marked both classes with CLSCompatible(false). This will allow the inheritors to use types like uint or ulong for the properties Id, which are usually mapped to the primary key of the corresponding DB tables. Negative Id-s (PK-s) do not make a lot of sense. --- .../NuGet/ExpressionSerialization.nuspec | 2 +- .../Serialization/Properties/AssemblyInfo.cs | 6 +++--- Aspects/Model/DomainEntity.cs | 3 +++ Aspects/Model/DomainValue.cs | 3 +++ Aspects/Model/Properties/AssemblyInfo.cs | 6 +++--- Aspects/NuGet/vm.Aspects.nuspec | 11 ++++++----- Aspects/Parsers/Properties/AssemblyInfo.cs | 6 +++--- Aspects/Properties/AssemblyInfo.cs | 6 +++--- Aspects/Wcf/Properties/AssemblyInfo.cs | 6 +++--- 9 files changed, 28 insertions(+), 21 deletions(-) diff --git a/Aspects/Linq/Expressions/Serialization/NuGet/ExpressionSerialization.nuspec b/Aspects/Linq/Expressions/Serialization/NuGet/ExpressionSerialization.nuspec index 0f21912..488579f 100644 --- a/Aspects/Linq/Expressions/Serialization/NuGet/ExpressionSerialization.nuspec +++ b/Aspects/Linq/Expressions/Serialization/NuGet/ExpressionSerialization.nuspec @@ -2,7 +2,7 @@ AspectExpressionSerialization - 1.0.11 + 1.0.12 Val Melamed Val Melamed diff --git a/Aspects/Linq/Expressions/Serialization/Properties/AssemblyInfo.cs b/Aspects/Linq/Expressions/Serialization/Properties/AssemblyInfo.cs index ebfc2e0..b0a8ad5 100644 --- a/Aspects/Linq/Expressions/Serialization/Properties/AssemblyInfo.cs +++ b/Aspects/Linq/Expressions/Serialization/Properties/AssemblyInfo.cs @@ -4,9 +4,9 @@ [assembly: AssemblyTitle("vm.Aspects.Linq.Expressions.Serialization")] [assembly: AssemblyDescription("Serializes and deserializes LINQ expression trees to and from XML documents.")] -[assembly: AssemblyVersion("1.0.11")] -[assembly: AssemblyFileVersion("1.0.11")] -[assembly: AssemblyInformationalVersion("1.0.11")] +[assembly: AssemblyVersion("1.0.12")] +[assembly: AssemblyFileVersion("1.0.12")] +[assembly: AssemblyInformationalVersion("1.0.12")] [assembly: InternalsVisibleTo( "vm.Aspects.Linq.Expressions.Serialization.Test, " + diff --git a/Aspects/Model/DomainEntity.cs b/Aspects/Model/DomainEntity.cs index 2778897..61ce277 100644 --- a/Aspects/Model/DomainEntity.cs +++ b/Aspects/Model/DomainEntity.cs @@ -1,5 +1,6 @@ using System; using System.ComponentModel.DataAnnotations; +using System.ComponentModel.DataAnnotations.Schema; using System.Diagnostics; using System.Diagnostics.CodeAnalysis; using vm.Aspects.Model.Repository; @@ -42,8 +43,10 @@ public override bool HasIdentity /// /// Gets or sets the store identifier. + /// The property is applied the attributes and with parameter Order = 0. /// [Key] + [Column(Order = 0)] public virtual TId Id { get { return _id; } diff --git a/Aspects/Model/DomainValue.cs b/Aspects/Model/DomainValue.cs index f84c552..9218601 100644 --- a/Aspects/Model/DomainValue.cs +++ b/Aspects/Model/DomainValue.cs @@ -1,5 +1,6 @@ using System; using System.ComponentModel.DataAnnotations; +using System.ComponentModel.DataAnnotations.Schema; using System.Diagnostics; using System.Diagnostics.CodeAnalysis; @@ -24,8 +25,10 @@ public abstract class DomainValue : BaseDomainValue, /// /// Gets or sets the store identifier. + /// The property is applied the attributes and with parameter Order = 0. /// [Key] + [Column(Order = 0)] public virtual TId Id { get { return _id; } diff --git a/Aspects/Model/Properties/AssemblyInfo.cs b/Aspects/Model/Properties/AssemblyInfo.cs index ee1cc27..08f484e 100644 --- a/Aspects/Model/Properties/AssemblyInfo.cs +++ b/Aspects/Model/Properties/AssemblyInfo.cs @@ -3,9 +3,9 @@ [assembly: AssemblyTitle("vm.Aspect.Model")] [assembly: AssemblyDescription("Defines the IRepository and related base classes and utilities - a framework of building domain object model.")] -[assembly: AssemblyVersion("1.0.11")] -[assembly: AssemblyFileVersion("1.0.11")] -[assembly: AssemblyInformationalVersion("1.0.11")] +[assembly: AssemblyVersion("1.0.12")] +[assembly: AssemblyFileVersion("1.0.12")] +[assembly: AssemblyInformationalVersion("1.0.12")] [assembly: System.Runtime.CompilerServices.InternalsVisibleTo( "vm.Aspects.Model.Tests, " + diff --git a/Aspects/NuGet/vm.Aspects.nuspec b/Aspects/NuGet/vm.Aspects.nuspec index 6d2d7fc..9c5af98 100644 --- a/Aspects/NuGet/vm.Aspects.nuspec +++ b/Aspects/NuGet/vm.Aspects.nuspec @@ -2,7 +2,7 @@ vm.Aspects - 1.0.11-beta + 1.0.12-beta Val Melamed Val Melamed @@ -12,10 +12,11 @@ A set of classes, utilities, etc. addressing various common cross-cutting concerns or extending existing similar libraries like Enterprise Library, Unity, etc. - * Changed the visibility of the field _id in the classes vm.Aspects.Model.DomainEntity and vm.Aspects.Model.DomainValue from private to protected. - This will allow the inheritors to modify the behavior of the property Id, without unnecessary duplicating the backing field. - * Marked both classes with CLSCompatible(false). This will allow the inheritors to use types like uint or ulong for the properties Id, - which are usually mapped to the primary key of the corresponding DB tables. Negative Id-s (PK-s) do not make a lot of sense. +* Changed the visibility of the field _id in the classes vm.Aspects.Model.DomainEntity and vm.Aspects.Model.DomainValue from private to protected. +This will allow the inheritors to modify the behavior of the property Id, without unnecessary duplicating the backing field. +* The property Id was applied the attributes KeyAttribute and ColumnAttribute with argument Order=0. +* Marked both classes with CLSCompatible(false). This will allow the inheritors to use types like uint or ulong for the properties Id, +which are usually mapped to the primary key of the corresponding DB tables. Negative Id-s (PK-s) do not make a lot of sense. https://github.com/vmelamed/vm/blob/master/LICENSE https://github.com/vmelamed/vm/tree/master/Aspects diff --git a/Aspects/Parsers/Properties/AssemblyInfo.cs b/Aspects/Parsers/Properties/AssemblyInfo.cs index c103cfe..39bdd78 100644 --- a/Aspects/Parsers/Properties/AssemblyInfo.cs +++ b/Aspects/Parsers/Properties/AssemblyInfo.cs @@ -6,9 +6,9 @@ [assembly: AssemblyTitle("vm.Aspects.Parser")] [assembly: AssemblyDescription("Text parsing readers, e.g. CSV/TSV reader.")] -[assembly: AssemblyVersion("1.0.11")] -[assembly: AssemblyFileVersion("1.0.11")] -[assembly: AssemblyInformationalVersion("1.0.11")] +[assembly: AssemblyVersion("1.0.12")] +[assembly: AssemblyFileVersion("1.0.12")] +[assembly: AssemblyInformationalVersion("1.0.12")] [assembly: System.Runtime.CompilerServices.InternalsVisibleTo( "vm.Aspects.Parsers.Tests, " + diff --git a/Aspects/Properties/AssemblyInfo.cs b/Aspects/Properties/AssemblyInfo.cs index 141b05f..d047356 100644 --- a/Aspects/Properties/AssemblyInfo.cs +++ b/Aspects/Properties/AssemblyInfo.cs @@ -2,9 +2,9 @@ [assembly: AssemblyTitle("vm.Aspects")] [assembly: AssemblyDescription("A set of classes addressing various common cross-cutting concerns.")] -[assembly: AssemblyVersion("1.0.11")] -[assembly: AssemblyFileVersion("1.0.11")] -[assembly: AssemblyInformationalVersion("1.0.11")] +[assembly: AssemblyVersion("1.0.12")] +[assembly: AssemblyFileVersion("1.0.12")] +[assembly: AssemblyInformationalVersion("1.0.12")] [assembly: System.Runtime.CompilerServices.InternalsVisibleTo( diff --git a/Aspects/Wcf/Properties/AssemblyInfo.cs b/Aspects/Wcf/Properties/AssemblyInfo.cs index 6852e56..4c1b522 100644 --- a/Aspects/Wcf/Properties/AssemblyInfo.cs +++ b/Aspects/Wcf/Properties/AssemblyInfo.cs @@ -3,9 +3,9 @@ [assembly: AssemblyTitle("Wcf")] [assembly: AssemblyDescription("A set of classes and generics simplifying the initial configuration work of creating WCF services.")] -[assembly: AssemblyVersion("1.0.11")] -[assembly: AssemblyFileVersion("1.0.11")] -[assembly: AssemblyInformationalVersion("1.0.11")] +[assembly: AssemblyVersion("1.0.12")] +[assembly: AssemblyFileVersion("1.0.12")] +[assembly: AssemblyInformationalVersion("1.0.12")] [assembly: System.Runtime.CompilerServices.InternalsVisibleTo( "vm.Aspects.Wcf.Test, " +