1.Upgrade FluentNHibernate.csproj, set TargetFrameworks to net6.0.
when compile using VS 2022 , the ide complain that , so I let ide upgrade the project.
net6.0 not required Reference System.ComponentModel.Annotations.
FluentNHibernateAnnotationsExtensions.cs
Set ColumnMapping.NotNull when [Required] present or not GetType().IsNullable().
Set ColumnMapping.Length when [MaxLength] present.
Configure GeneratorMapping.Class to [assinged] when [DatabaseGenerated(DatabaseGeneratedOption.None)] present.
Configure GeneratorMapping.Class to [identity] when [DatabaseGenerated(DatabaseGeneratedOption.Identity)] present.
3.Update DefaultAutomappingConfiguration.cs.
IsId: return true when [Key] present on member.
4.Update IdentityStep.cs.
Support [DatabaseGenerated(DatabaseGeneratedOption.None)]
Support [DatabaseGenerated(DatabaseGeneratedOption.Identity)]
5.Update PropertyStep.cs.
Support [MaxLength], [Required], or GetType().IsNullable().
1.Upgrade FluentNHibernate.csproj, set TargetFrameworks to net6.0. when compile using VS 2022 , the ide complain that , so I let ide upgrade the project. net6.0 not required Reference System.ComponentModel.Annotations.
3.Update DefaultAutomappingConfiguration.cs. IsId: return true when [Key] present on member.
4.Update IdentityStep.cs. Support [DatabaseGenerated(DatabaseGeneratedOption.None)]
Support [DatabaseGenerated(DatabaseGeneratedOption.Identity)]
5.Update PropertyStep.cs. Support [MaxLength], [Required], or GetType().IsNullable().