Ninject v4.0.0-beta.1 Release Notes
Release Date: 2022-10-05 // over 1 year ago-
๐ Changed
- โฌ๏ธ Dropped support for .NET Framework 4.5. We now only provide support for the .NET Framework 4.6, .NET 6 and .NET Standard 2.0.
- ๐ Changed return value of IBindingResolver (and implementing classes) from
IEnumerable<IBinding>
toICollection<IBinding>
. - The
IConstructorScorer ConstructorScorer
andICollection<IInjectionHeuristic> InjectionHeuristics
properties has been removed from (I)Selector - ๐ Changed return value of
ISelector.SelectConstructorsForInjection(Type type)
(and implementing classes) fromIEnumerable<ConstructorInfo>
toConstructorInfo[]
. - The
T Get<T>(string key, T defaultValue)
andvoid Set(string key, object value)
methods have been removed from (I)NinjectSettings. - The
GetBindings(Type service)
method in IKernel and KernelBase now returnsIBinding[]
instead ofIEnumerable<IBinding>
. - โ Removed
IHaveKernel
inheritance fromIBindingSyntax
. - โ Removed
IInjectorFactory InjectorFactory
property fromPropertyInjectionStrategy
. - โ Added a
PropertyInjection
setting that can be used to control whether property injection is enabled. By default, property injection is enabled. - โ Added a
MethodInjection
setting that can be used to control whether method injection is enabled. By default, method injection is enabled. - ๐ Changed type of parameters argument in
Request
constructor fromIEnumerable<IParameter>
toIReadOnlyList<IParameter>
. - ๐ Changed type of parameters argument in
IResolutionRoot.CreateRequest(...)
fromIEnumerable<IParameter>
toIReadOnlyList<IParameter>
. - ๐ Changed type of parameters argument in
KernelBase.CreateRequest(...)
fromIEnumerable<IParameter>
toIReadOnlyList<IParameter>
. - ๐ Changed type of Parameters property in
IBindingConfiguration
(and implementing classes) fromICollection<IParameter>
toIList<IParameter>
. - ๐ Changed type of Parameters property in
Request
andContext
fromIEnumerable<IParameter>
toIReadOnlyList<IParameter>
. - โ Added a
object ResolveSingle(IRequest request)
method toIResolutionRoot
which is optimized for resolving a single instance of a given service. This new method is used in theGet
,TryGet
andTryGetAndThrowOnInvalidBinding
extension method.
๐ Fixed
- Bind/Rebind to a constant generic List always returns an empty list #333
Previous changes from v3.3.6
-
๐ Fixed
- Infinite loop when call
TryGet<T>(string name)
#393 VerifycationException
when inject pointer type (.NET Framework only)
- Infinite loop when call