Page 1 of 1
Pros and Cons of each Entity Template type ie POCO, Entity Objects etc.
Posted: Tue 12 Feb 2013 17:00
by EdB
Hi All,
I am trying to figure out the merits of each of the Model Generation Templates. My current preference is POCO since it is simple. However I may be missing some benefits of the others. Also I am using buddy classes to hold Data Annotations for validation.
Many thanks,
Ed
Re: Pros and Cons of each Entity Template type ie POCO, Entity Objects etc.
Posted: Wed 13 Feb 2013 15:49
by Shalex
DbContext template is designed for generating a strongly-typed DbContext class and persistence ignorant entity classes.
EntityObject template is designed for generating a strongly-typed ObjectContent class and persistence-aware classes.
POCO Entity template is designed for generating a strongly-typed ObjectContext class and classes with persistence ignorance.
Self-Tracking Entity template is designed for generating a strongly-typed ObjectContext class and self-tracking entity classes.
Repository and Unit of Work template is designed for generating Repositories and Unit of Work for Entity Framework model.
Re: Pros and Cons of each Entity Template type ie POCO, Entity Objects etc.
Posted: Thu 14 Feb 2013 12:46
by EdB
Hi,
Thanks for this.
Your wording I recollect is from the documentation. However it does not really help me understand which one I should use. For example is one more efficient or more performant, is one simpler, does one offer more features etc etc. As I say at the moment, due to simplicity, I have opted for POCO.
Thanks,
Ed
Re: Pros and Cons of each Entity Template type ie POCO, Entity Objects etc.
Posted: Mon 18 Feb 2013 16:48
by Shalex
Tips for general differences between templates are mentioned at
http://stackoverflow.com/questions/5340 ... ectcontext. Be aware that Devart's templates include more features (which are not properly documented at the moment) comparing to the standard templates. The design time interface of Entity Developer allows to get acquainted with the template's functionality, also the embedded T4 Editor makes it possible to adjust template for your needs.
The description of the Entity Developer EF DbContext template is available at
http://blogs.devart.com/dotconnect/enti ... plate.html.
Re: Pros and Cons of each Entity Template type ie POCO, Entity Objects etc.
Posted: Mon 18 Feb 2013 17:19
by EdB
Hi,
Thanks for this.
I think a DevArt blog on the pros and cons of each type would be very worthwhile then. Any chance? Especially as Devart ED adds functionality.
It seems that my current POCO choice is correct and pragmatic, subject to future enlightenment !!!
Thanks.
Re: Pros and Cons of each Entity Template type ie POCO, Entity Objects etc.
Posted: Tue 19 Feb 2013 16:18
by Shalex
I think a DevArt blog on the pros and cons of each type would be very worthwhile then. Any chance? Especially as Devart ED adds functionality.
Thank you for your suggestion. We will consider the possibility of creating the corresponding blog article.