views:

180

answers:

4

I currently use the Entity Framework designer to generate my persistance objects and I also user POCO view models for the ASp.NET MVC view.

I've read and listened to a lot of people talking about the good support for POCO's in EF4 as well as POCO's in general but I can't seem to work out what advantage, if any I'll get from using them.

In our application, we WILL be using SQL Server so it's not like we need so separate out for different databases.

Why would I want to use POCO's as opposed to the designer generated classes?

A: 
  1. Easier to unit test
  2. I find when you have many entities (100+) using the designer is painful and POCO objects are easy to create and maintain.
Craig
A: 

Answered here :http://stackoverflow.com/questions/2635953/what-are-the-big-advantages-to-have-poco-with-orm

Pierre 303
I'm marking this as the answer as I didn't see this when I created the question.
Alastair Pitts
+1  A: 

POCO offers better extensibility/reuse of your Domain Model as you're not tied to any specific ORM framework.

Daz Lewis