IoC (Windsor) - 什么是“默认接口”?
有人可以解释一下“
container.Register(AllTypes.FromAssemblyContaining(typeof(BigCompanyRepository))
.WithService.DefaultInterface()
默认界面”和
container.Register(AllTypes.FromAssemblyContaining(typeof(BigCompanyRepository))
.WithService.AllInterfaces()
“默认界面”之间的区别吗?
Can someone please explain the difference between
container.Register(AllTypes.FromAssemblyContaining(typeof(BigCompanyRepository))
.WithService.DefaultInterface()
and
container.Register(AllTypes.FromAssemblyContaining(typeof(BigCompanyRepository))
.WithService.AllInterfaces()
What is meant by a "default interface"?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
寻找一个实现通过删除前导的
I
来实现接口:然而,在我看来,使用此功能有点过度丰富的 1:1接口。
It's a heuristic that looks for an implementation of an interface by removing the leading
I
:However, in my opinion, using this feature smells of an over-abundance of 1:1 interfaces.