in

Chennai .Net User Group

A platform that enables you to Learn, Share & Grow (India's first .Net user group)

Shiju Varghese's Blog

Microsoft Unity 2.0 Released


Microsoft's dependency injection framework Unity Application Block (Unity) has reached version 2.0. The release available on Codeplex at http://unity.codeplex.com/

Unity 2.0 

 UnityContainer Fluent Interface

Unity 2.0 provides a fluent interface for type configuration. Now you can call all the methods in a single statement, as shown in the following code.

 

IUnityContainer container = new UnityContainer()

.RegisterType<IFormsAuthentication, FormsAuthenticationService>()

.RegisterType<IMembershipService, AccountMembershipService>()

.RegisterInstance<MembershipProvider>(Membership.Provider)

.RegisterType<IDinnerRepository, DinnerRepository>();  

 

Read the complete post at http://feedproxy.google.com/~r/ShijuVBlog/~3/c_TUAzSAnJk/microsoft-unity-2-0-released.aspx

Only published comments... May 06 2010, 06:43 AM by Shiju Varghese's Blog
Filed under:
Copyright © 2002-2008 Chennai .Net User Group. All Rights Reserved. Microsoft and Microsoft logo's are trademarks of Microsoft Corporation