Top "Unity-container" questions

The Unity Application Block (i.e. Unity) is a lightweight, extensible dependency injection container for .NET with support for interception.

MVC, EF - DataContext singleton instance Per-Web-Request in Unity

I have a MVC 3 web application, where I am using the Entity Framework for the data access. Furthermore, I have …

asp.net-mvc-3 entity-framework unity-container ioc-container
Activation error occured while trying to get instance of type ICacheManager, key "Cache Manager"

I seem to have hit a wall here and would appreciate some help from anyone who is able to on …

c# .net caching unity-container enterprise-library
Comparing Castle Windsor, Unity and StructureMap

In a follow up to Krzysztof’s statement that Windsor does a lot more than other IoC’s, I wanted …

dependency-injection castle-windsor structuremap unity-container ioc-container
UnityContainer.Resolve or ServiceLocator.GetInstance?

It could seem a stupid question because in my code everything is working, but I've registered a singleton this way …

c# dependency-injection inversion-of-control unity-container
Microsoft Unity. How to specify a certain parameter in constructor?

I'm using Microsoft Unity. I have an interface ICustomerService and its implementation CustomerService. I can register them for the Unity …

c# asp.net unity-container ioc-container
How to remove(unregister) registered instance from Unity mapping?

I meet one problem that i can't solve now. I have the following: UnityHelper.DefaultContainer.RegisterInstance(typeof(IMyInterface), "test", instance); …

c# unity-container ioc-container instance registering
How to Inject Log4Net ILog implementations using Unity 2.0

Ultimately this has to do with setting up log4Net but generically the problem is not logging specific. Generically what …

c# dependency-injection unity-container log4net castle-windsor
How to inject dependency property using Ioc Unity

I have the following classes: public interface IServiceA { string MethodA1(); } public interface IServiceB { string MethodB1(); } public class ServiceA : IServiceA { public …

c# inversion-of-control unity-container ioc-container property-injection
WPF unity Activation error occured while trying to get instance of type

I am getting the following error when trying to Initialise the Module using Unity and Prism. The DLL is found …

wpf unity-container prism modularity
How do I correctly use Unity to pass a ConnectionString to my repository classes?

I've literally just started using the Unity Application Blocks Dependency Injection library from Microsoft, and I've come unstuck. This is …

c# dependency-injection inversion-of-control unity-container repository-pattern