In ASP.NET Core, does the IoC ASP Startup Class solve what the Managed Extensibility Framework solved with a catalog and container?

六眼飞鱼酱① 提交于 2019-12-08 04:00:08

问题


I have read this, MEF (Managed Extensibility Framework) vs IoC/DI but it is dated. Since then MEF was added to Core.

When I look at MEF and the IoC in ASP.NET Core, I cannot tell a lot of differences for a plugin architecture. Both "wire-up" dependencies. If I wanted to create a plugin in a Core application using IoC (the built in IoC), why not just change my ConfigureService methods? Is that the same as decorating imports and exports in MEF? How is composition different here, in 2017 (close enough)?

来源:https://stackoverflow.com/questions/41269797/in-asp-net-core-does-the-ioc-asp-startup-class-solve-what-the-managed-extensibi

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!