MGen is a code generator library that can generate C# classes from interfaces.
The first thing you will need to do is to install the MGen NuGet packages.
Install-Package MGen
Install-Package MGen.Abstractions
Here is a simple example of how it works:
[Generate]
public interface IHaveAnGuidId
{
Guid Id { get; set; }
}
The generated code will look like:
public class HaveAnGuidIdModel : IHaveAnGuidId
{
public System.Guid Id
{
get
{
return _Id;
}
set
{
_Id = value;
}
}
private System.Guid _Id;
public HaveAnGuidIdModel()
{
}
}
For a full list of supported features read this.
Icons made by Freepik from www.flaticon.com is licensed by CC 3.0 B