开发者

Repository pattern: Dynamic class generation

开发者 https://www.devze.com 2022-12-19 22:08 出处:网络
I would like to implement the repository pattern, having my domain classes being independent from my repository implementation.

I would like to implement the repository pattern, having my domain classes being independent from my repository implementation.

but maintain my domain classes -on schema updates using EF for example- is really expe开发者_C百科nsive.

Do you know someway to automatize domain classes updates based on the ORM classes? -using T4 templates or something similar...


Now i don't know if you are working with EF 4, but in that case Poco templates have recently been released on the Ado.Net Team Blog


One solution is to use a tool like Automapper.

0

精彩评论

暂无评论...
验证码 换一张
取 消