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.
我正在查看 EntityFramework 的 CTP5 和 code first fluent interface。它看起来很不错,但是有没有办法让 DbContext 只公开接口类型,并且在流式接口的模型绑定器中定义要使用的具体实现?
不,从 CTP5 开始,EF Code First 不支持接口,并且计划在今年发布的 RTM 中不太可能支持此功能。