All Versions
44
Latest Version
Avg Release Cycle
25 days
Latest Release
564 days ago
Changelog History
Page 1
Changelog History
Page 1
-
v5.4.1 Changes
May 16, 2022๐ Fixed
- ๐ป Type load exception when the library was trimmed.
-
v5.4.0 Changes
May 03, 2022๐ Changed
Resolve<IEnumerable<>>(name)
now returns each service that has the same name. ### โ AddedResolveAll(name)
that returns each service that has the same name. ### โ Removed- 0๏ธโฃ Obsolete
Resolve()
method with thenullResultAllowed
parameter, it was replaced byResolveOrDefault()
. - Each obsolete
ResolveFactory<>()
method as their functionality is equivalent toResolve<Func<>>()
. - ๐ง Obsolete
.WithRuntimeCircularDependencyTracking()
container configuration option in favor of parameterized factory delegates.
-
v5.3.0 Changes
April 10, 2022โ Added
WithDynamicResolution()
registration option to indicate that the service's resolution should be handled by a dynamicResolve()
call on the currentIDependencyResolver
instead of a pre-built instantiation expression.- ๐ Support for resolving custom Delegate types alongside
Func<>
.
-
v5.2.1 Changes
March 12, 2022๐ Fixed
- Consolidate
Resolve()
API, using method overloads instead of optional parameters.
- Consolidate
-
v5.2.0 Changes
March 07, 2022๐ Fixed
- Unable to resolve IHubContext. #114
โ Added
- Null-safety by enabling null-state analysis.
- 0๏ธโฃ Option to exclude a factory's result from dispose tracking, even if it would be tracked by default. This gives the ability to decide within the factory delegate that the result should be tracked or not.
cs .Register<Service>(options => options .WithFactory<IRequestContext>(requestContext => requestContext.ExcludeFromTracking(/* get an existing or instantiate a new service */) ) );
- 0๏ธโฃ A new
ResolveFactoryOrDefault()
method that allowsnull
results. - 0๏ธโฃ A new
ResolveOrDefault()
method that allowsnull
results. - ๐
ValueTuple<,>
metadata support.
๐ Changed
- 0๏ธโฃ
Resolve()
with thenullResultAllowed
parameter became obsolete, it was replaced byResolveOrDefault()
. - Each
ResolveFactory<>()
method became obsolete as their functionality is equivalent toResolve<Func<>>()
.
โ Removed
nullResultAllowed
parameter ofResolveFactory()
.
-
v5.1.0 Changes
February 27, 2022๐ Changed
- Marked the
.WithRuntimeCircularDependencyTracking()
container configuration option as Obsolete in favor of parameterized factory delegates.
- Marked the
-
v5.0.1 Changes
February 10, 2022๐ Changed
- Converted the
ServiceContext
to a read-only struct. - Made the
.AsServiceContext()
extension method ofExpression
public.
- Converted the
-
v5.0.0 Changes
February 09, 2022โ Added
- โ Additional metadata registration option.
- ๐ Support for requesting a service along with its identifier.
- ๐ Support for per-request lifetime.
- ๐ New, clearer API for wrapper extensions.
๐ Fixed
- There was a bug in the expression compiler that resulted in wrong IL generation in case of value types inside
IEnumerable<>
.
๐ Changed
- ๐
Tuple<>
requests are not resolved with services in all its items anymore. It's became part of the newly introduced resolution with metadata feature. - The
IResolver
interface became the base for the newly introducedIServiceWrapper
andIServiceResolver
interfaces. These became the main entrypoints for [container extensions](advanced/wrappers-resolvers). - To make the dependency overrides available in factories the
IResolutionContext
was bound to the generated expression tree and the compiled delegate. (#105) This temporary solution could lead issues as the resolution context is static between the compiled delegates, however the dependency overrides are not.
To resolve this, a new
IRequestContext
parameter is introduced for each compiled factory delegate that can be used to access overrides. (The same context object is used to produce and track per-request services)container.Register<Service>(options => options. WithFactory<IRequestContext>(requestContext => { // access the overrides through: requestContext.GetOverrides() // or: requestContext.GetDependencyOverrideOrDefault<OverrideType>() }))
โ Removed
- ๐ Support of circular dependencies with
Lazy<>
along with the.WithCircularDependencyWithLazy()
container configuration option.
-
v4.1.0 Changes
November 21, 2021๐ Fixed
IsRegistered()
returnstrue
only when the container has a registration with the given type (and name).CanResolve()
returnstrue
only when at least one of the following is true:- The given type is registered in the current or one of the parent containers.
- The given type is a closed generic type and its open generic definition is registered.
- The given type is a wrapper (
IEnumerable<>
,Lazy<>
,Func<>
, orTuple<>
) and the underlying type is registered. - The given type is not registered but it's resolvable and the unknown type resolution is enabled.
-
v4.0.0 Changes
November 18, 2021โ Removed
- ๐ .NET 4.0 support.