Created
September 23, 2014 16:41
-
-
Save andrebaltieri/29e0fe2382f2e35d7e42 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// DI | |
var container = new UnityContainer(); | |
container.RegisterType<IUserRepository, UserRepository>(new HierarchicalLifetimeManager()); | |
container.RegisterType<ICustomerRepository, CustomerRepository>(new HierarchicalLifetimeManager()); | |
config.DependencyResolver = new UnityResolver(container); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment