Unity 5.0.0

Unity Container Library as single package

There is a newer version of this package available.
See the version list below for details.
Install-Package Unity -Version 5.0.0
dotnet add package Unity --version 5.0.0
<PackageReference Include="Unity" Version="5.0.0" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add Unity --version 5.0.0
The NuGet Team does not provide support for this client. Please contact its maintainers for support.

Release 5.0.0

After few years of inactivity we are finally updating Unity library. The main goal of this release was to preserve compatibility with previous distribution v4.0.1 as much as possible. Unfortunately loss of original signing key prevented creation of compatible assemblies. To eliminate conflicts assembly names and namespaces were changed.
The Unity Container has been split into following assemblies:

  • Unity.Abstractions.2.0.0
  • Unity.Container.5.0.0
  • Unity.ServiceLocation.2.0.0
  • CommonServiceLocator.2.0.1

Each of these is available as individual package but Abstractions and Container also distributed as library via Unity.5.0.0 package.

All 1220 tests from previous release are still passing.

New features

  • Unity container no longer references CommonServiceLocator
  • Added support for .NET 4.0, 4.5, 4.7, .NET Core 1.0+ and .NET Standard 1.0+ where available.
  • Container internally uses ConcurrentDictionary to improve multi threading
  • Added DelegateInjectionFactory which allows free form delegate to serve as Injection Factory
  • Added support for IEnumerable<T> resolution
  • Registration speed increased about one order of magnitude See data

Breaking changes

  • Unity has been split into Unity.Abstractions and Unity.Container
  • Moved ServiceLocation functionality into separate package Unity.ServiceLocation
  • Interface IBuilderContext now has reference to IUnityContainer. This change was required to speed up dependency resoluton.
  • TearDown has been removed from IUnityContainer
  • ResolveAll has been converted to Extension method

Release 5.0.0

After few years of inactivity we are finally updating Unity library. The main goal of this release was to preserve compatibility with previous distribution v4.0.1 as much as possible. Unfortunately loss of original signing key prevented creation of compatible assemblies. To eliminate conflicts assembly names and namespaces were changed.
The Unity Container has been split into following assemblies:

  • Unity.Abstractions.2.0.0
  • Unity.Container.5.0.0
  • Unity.ServiceLocation.2.0.0
  • CommonServiceLocator.2.0.1

Each of these is available as individual package but Abstractions and Container also distributed as library via Unity.5.0.0 package.

All 1220 tests from previous release are still passing.

New features

  • Unity container no longer references CommonServiceLocator
  • Added support for .NET 4.0, 4.5, 4.7, .NET Core 1.0+ and .NET Standard 1.0+ where available.
  • Container internally uses ConcurrentDictionary to improve multi threading
  • Added DelegateInjectionFactory which allows free form delegate to serve as Injection Factory
  • Added support for IEnumerable<T> resolution
  • Registration speed increased about one order of magnitude See data

Breaking changes

  • Unity has been split into Unity.Abstractions and Unity.Container
  • Moved ServiceLocation functionality into separate package Unity.ServiceLocation
  • Interface IBuilderContext now has reference to IUnityContainer. This change was required to speed up dependency resoluton.
  • TearDown has been removed from IUnityContainer
  • ResolveAll has been converted to Extension method

Release Notes

Entire Unity Library as single package.

Dependencies

This package has no dependencies.

Showing the top 10 GitHub repositories that depend on Unity:

Repository Stars
Sonarr/Sonarr
Smart PVR for newsgroup and bittorrent users.
ServiceStack/ServiceStack
Thoughtfully architected, obscenely fast, thoroughly enjoyable web services for all
Radarr/Radarr
A fork of Sonarr to work with movies à la Couchpotato.
unoplatform/uno
Build Mobile, Desktop and WebAssembly apps with C# and XAML. Today. Open source and professionally supported.
MichaCo/CacheManager
CacheManager is an open source caching abstraction layer for .NET written in C#. It supports various cache providers and implements many advanced features.
jakubgarfield/Bonobo-Git-Server
Bonobo Git Server for Windows is a web application you can install on your IIS and easily manage and connect to your git repositories. Go to homepage for release and more info.
XLabs/Xamarin-Forms-Labs
Xamarin Forms Labs is a open source project that aims to provide a powerful and cross platform set of controls and helpers tailored to work with Xamarin Forms.
Windows-XAML/Template10
Making Windows 10 apps great again
lidarr/Lidarr
Looks and smells like Sonarr but made for music.
OpenCover/opencover
A code coverage tool for .NET 2 and above (WINDOWS OS only), support for 32 and 64 processes with both branch and sequence points

Version History

Version Downloads Last updated
5.11.1 366,833 6/20/2019
5.10.3 260,779 4/4/2019
5.10.2 71,703 3/23/2019
5.10.1 30,044 3/19/2019
5.10.0 27,045 3/18/2019
5.9.8 16,561 3/17/2019
5.9.7 84,681 3/4/2019
5.9.6 11,132 3/2/2019
5.9.5 69,206 2/18/2019
5.9.4 32,583 2/9/2019
5.9.3 262,087 1/30/2019
5.9.2 42,315 1/25/2019
5.9.1 9,660 1/24/2019
5.9.0 24,935 1/23/2019
5.9.0-RC1 3,545 1/21/2019
5.9.0-RC 2,175 1/14/2019
5.8.13 305,330 12/7/2018
5.8.12 55,399 12/4/2018
5.8.11 773,649 9/1/2018
5.8.10 67,473 8/27/2018
5.8.9 15,524 8/25/2018
5.8.8 7,642 8/24/2018
5.8.7 35,757 8/22/2018
5.8.6 969,036 4/19/2018
5.8.5 86,676 4/6/2018
5.8.4 41,636 3/31/2018
5.8.3 8,507 3/30/2018
5.8.2 6,773 3/30/2018
5.8.1 24,167 3/28/2018
5.8.0 33,774 3/27/2018
5.7.3 232,789 3/3/2018
5.7.2 12,815 3/3/2018
5.7.1 14,327 3/2/2018
5.7.0 19,404 3/1/2018
5.6.1 122,558 2/22/2018
5.6.0 110,084 2/13/2018
5.5.8 37,933 2/9/2018
5.5.6 151,750 1/23/2018
5.5.5 202,453 1/11/2018
5.5.4 69,594 1/3/2018
5.5.3 11,495 1/3/2018
5.5.2 14,234 12/30/2017
5.5.1 10,779 12/30/2017
5.5.0 61,454 12/20/2017
5.4.0 29,410 12/18/2017
5.3.2 151,783 12/2/2017
5.3.1 205,459 11/21/2017
5.3.0 33,466 11/19/2017
5.2.1 66,052 11/15/2017
5.2.0 290,042 11/12/2017
5.1.2 85,030 10/30/2017
5.1.0 17,957 10/29/2017
5.0.2 24,114 10/25/2017
5.0.1 30,917 10/23/2017
5.0.0 38,562 10/19/2017
4.0.1 7,976,576 10/6/2015
3.5.1405-prerelease 116,718 5/15/2014
3.5.1404 3,741,731 4/22/2014
3.0.1304.1 1,172,608 8/29/2013
3.0.1304 327,407 4/26/2013
3.0.1208-Preview 12,113 8/10/2012
2.1.505.2 1,688,850 8/2/2012
2.1.505 1,497,393 5/11/2011
2.0.0 325,639 5/5/2011
1.0.0-beta 5,478 12/2/2015
Show less