且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

常规应用程序性能-加快加载时间...

更新时间:2023-02-27 14:19:34

 

 

您好JaedenRuiner,

Hi JaedenRuiner,

A)是的,MEF框架正是出于这个原因而设计的;只加载您需要的东西.您还可以将dll加载到工作目录中,然后将其加载到IoC容器中(例如Entlib中的Unity.

A) Yes you can, the MEF framework is designed exactly for this reason; only load stuff that you need. You could also load dll's in a working directory and have them loaded into your IoC container (such as Unity from Entlib.

B)不,根据我的经验,它不会运行得更快

B) no, in my expierence it will not run any faster

C)是.使用IoC容器或MEF延迟加载依赖项.

C) Yes. Have the dependencies loaded lazily using an IoC container or using MEF.

请查看

Have a look at http://blogs.msdn.com/b/brada/archive/2008/09/29/simple-introduction-to-composite-applications-with-the-managed-extensions-framework.aspx for more information regarding getting started with MEF.

亲切的问候,
汤姆·德·科宁(Tom de Koning)

Kind regards,
Tom de Koning