Use Prism.Unity.UnityBootstrapper with Unity.IUnityContainer

随声附和 提交于 2020-01-14 14:11:48

问题


I’ve upgraded my project today to Prism 6.3.0 and Unity 5.3.1. Before that, I had Prism 5 and Unity 4.

Now I’m running into problems with the Prism.Unity.UnityBootstrapper: it seems that the Container field is still a Microsoft.Practices.Unity.IUnityContainer instead of Unity.IUnityContainer.

I had hoped that the upgrade would cleanly cut all references to Microsoft.Practices.Unity off of my project, but it seems that I’m still forced to use the “old” Prism library, at least in parts.

Why does this situation arise, and what do I do to make it right? Am I missing something?


回答1:


Unity 5.x is not supported in Prism yet. So, you will have to stick with 4.x until that happens. My understanding is, it is a goal of the team to support Unity 5.x in Prism 7 and up.

As you mentioned in your comment, there has been a lot of talk in the GitHub repo for Prism about the changes that came along with Unity 5. Glad to know that there are people willing to take on Unity, and move it forward, though.



来源:https://stackoverflow.com/questions/47542873/use-prism-unity-unitybootstrapper-with-unity-iunitycontainer

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