CatFactory
CatFactory copied to clipboard
Add Fluent API for Class Definition
Add extension methods to allow reduce syntax on create class definitions.
Proposed design:
var classDefinition = ClassDefinition
.New(AccessModifier.Public, "EmployeeController", "ShanghaiCat.API.Controllers", baseClass: "ControllerBase")
.IsPartial()
.AddDefaultCtor()
;
Output:
namespace ShanghaiCat.API.Controllers
{
public partial class EmployeeController : ControllerBase
{
public EmployeeController()
{
}
}
}