This project is read-only.

Applying attributes to the generated business objects

Apr 12, 2010 at 2:15 PM


Does anybody know how additional attributes can be applied to the properties in the POCO generated by the framework. I know you can use System.ComponentModel.DataAnnotations library to apply attributes but I am not sure it will override any of the attributes already present or not. Any samples of how to do this will be helpful.



Apr 20, 2010 at 3:33 AM

The best way to handle this is to override the existing generator.

1. You will need to start by reading the following article.

2. Get the latest code from SVN. I made the DTOGenerator public.

3.  Get the example code from SVN located at. I added a new class OverrideDTOGenerator and OverrideDTOTemplate.