C# 8 is on the way and better to early than too late should be planned the implementation of the new features (Introducing Nullable Reference Types in C#).
public class Blog
{
public int BlogId { get; set; }
public string Url { get; set; } //In C# 8 this should be required by default
public string? Url2 { get; set; } //In C# 8 this should be optional by default
//Needs EF support for constructors with parameters
public Blog(string url)
{
Url = url;
}
}
A new logic is needed for mapping of e. g. string: Required and Optional Properties
Support for constructors with Parameters is required: Flexible mapping to CLR types and members (Custom O/C Mapping #240)
This list is probably not complete.
C# 8 is on the way and better to early than too late should be planned the implementation of the new features (Introducing Nullable Reference Types in C#).
A new logic is needed for mapping of e. g. string: Required and Optional Properties
Support for constructors with Parameters is required: Flexible mapping to CLR types and members (Custom O/C Mapping #240)
This list is probably not complete.