问题
I currently enjoy working with NHibernate + Fluent NHibernate. I considered Entity Framework v1 because of its mature Linq support but I do not like working with clicky designers; and it did not support POCO, anyway. Now EF v4 does support POCOs; however, does it still require to use designers? Well, maybe I can edit those XML files but it cannot be considered a programming activity (unless you're doing J2EE I think).
So, would I be able to use Entity Framework only from the C# code, including model definition, etc?
回答1:
Yes,
There is an add-on to .NET 4.0 that allows you to do this without a designer, it is called Code-Only you can find it here: In the CTP for Beta 2
The current version works against EF / .NET 4.0 Beta 2.
Check out this post on the EF design blog more on how to use Code-Only. Also check on this post on my blog.
Hope this Helps.
Alex
来源:https://stackoverflow.com/questions/1694297/does-entity-framework-4-0-allow-to-work-without-designers