Helps to generate .NET Core Entity files from StarUML ER Diagram.
The format of generated files is based on .NET EF Core
- Select the ER Diagram to be generated.
- Fill in the output directory path
- Entity files will be generated in the output path.
- Generate entities
- Generate
[StringLength]annotation iflengthis defined - Generate
[Key]annotation ifPKis defined - Generate
[DatabaseGenerated(DatabaseGeneratedOption.Identity)]annotation if the primary key is type of Guid - Generate
requiredkeyword ornullable typeif the field is defined asNot nullorNullablerespectively - Generate properties based on defined columns
- Generate relationships
- Generate one-to-many or one-to-one relationship based of EF Core convention
- All columns which are deleted from view ONLY will be also generated. Please delete columns from model to have more accurate generated entities.
- This extensions can't cover all conditions. It's just help to create entity files faster. Please review the generated files before applying to application.
- Add plural name converter
- Use
requiredkeyword instead of[Required]annotation - Add application context file to define relationships
- Remove "Entity" in entity name
- Namespace can be customized