Extending Prism/Unity

Topics: Prism v2 - Silverlight 2, Prism v2 - WPF 3.5
Apr 18, 2009 at 6:01 AM
I specifically would like to be able to extend the resolution of types for Silverlight. In this case, I am using the Ref attribute to specify additional .xap files to load ondemand.  But having to load the Module instead of resolving doing the loading is troublesome to me.  What i'd like to do is add metadata to the catalog (that part is simple) that I can look through for the interface I want and load a module (or group) as needed to resolve the type. There are some odd things about asynchronity that i'll need to fix, but here comes the question:

- To extend the framework, i'd like to do something outside the source code (e.g. provide something that user could opt into). Where do I start?  I though that a new UnityExtension (a Strategy) but not sure that is too low to get at the catalog data.  I also considered a ServiceLocator extension but that seems too high level (as users may IUnityContainer.Resolve<>()).  

Any nudgess in the right direction would be great.  Don't worry about how I am going to accomplish my stated goal, but any advice on where to extend to get notified of potential Resolves (from users or from constructor injection) would be great.