Silverlight - Prism, Unity and Framework Managed Extensibility Framework,

I am trying to create a line of business applications using Silverlight. I felt like I was doing good, and then I asked some questions. Immediately I became very confused. I see discussions around Prism, Unity and the Framework for Managed Extensibility. However, they all look as if they are trying to solve the same problem. Am I nuts? How do these three elements compare / contrast with each other?

Thanks!

+4
source share
3 answers

I recommend listening to Herding Code podcasts with Glenn Block. ( Part 1 and Part 2 ). He goes into this topic in much more detail than we can answer here.

As the saying goes -

MEF and Unity are two things that have quite a few overlaps. Prism in its form by default uses Unity to inject dependencies. You can use Prism with MEF if you want, instead.

Prism is more designed to create composite applications. MEF, on the other hand, deals with extensibility. Of course, there are several matches in goals, but the main factor of movement is different.

  • In the case of Prism, it's all about organizing well-known code.
  • MEF, on the other hand, talks about opening up new code and the right injection.

The newest guide that I saw, with which I completely agree, was simply posted on the Glenn blog blog : "If you start Fresh you can use MEF for the modularity and general aspects of your composite application. Where possible, you can use a bit Prism. "

+5
source

http://blogs.msdn.com/gblock/archive/2009/12/02/mef-and-prism-to-be-or-not-to-be.aspx

Today was this post discussing two scenarios in which MEF and Prism work together to provide solutions. Each script uses functions that are not found in each, with 80/20 rules for those functions that they share.

0
source

Despite the fact that there is overlap, significant differences from the type of 30,000:

Unity is an IOC container. Use it to make your application more free.

Prism is the desire for your user interface to be more loosely coupled. As Reed mentioned, he uses Unity to help with this.

MEF is designed to make your code extensible. This is useful when interacting with code that will be written by someone else. For example, if your application will support plugins.

0
source

All Articles