Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
实体框架女王认为EF4 Code-First 对 DDD 人来说确实很有吸引力。这种说法也出现在许多其他地方。
我的问题是:为什么 Code-First 比 Model-First 更有吸引力?我会认为后者更符合 DDD 的工作方式?
Model-First 是指数据库模型。Code-First 是指代码中的领域模型。DDD 通常更喜欢 Code-First,因为数据库模型是一个持久性问题,它总是在 DDD 中的代码模型之后退居二线。