Hello Norbert,
You can add constructors to the generated persistent classes by editing the Specific.ttinclude file, located at
C:\Program Files\Telerik\OpenAccess ORM\dsl2010\CodeGenerationTemplates\CSharp\Includes. At line 133 you will find a method called GenerateClass, which is responsible for generating the code of the persistent classes. You can extend it with a constructor as shown below, I have added comments for the code that I have added:
Once you see the constructors generated, I believe you will easily manage to generate the rest of the code you want. Just note that you need to save the rlinq file or use the
Run Custom Tool command from the rlinq's context menu in order to regenerate the persistent classes.
Hope that helps.
Regards,
Alexander
the Telerik team
Q3’11 of Telerik OpenAccess ORM is available for download. Register for the What's New in Data Tools webinar to see what's new and get a chance to WIN A FREE LICENSE!