IInstanceProvider<T> and IFactory<T> have identical APIs and it seems pointless keeping them both,
Instead if an [Instance] field/property or a [Factory] method returns something of, or inheriting from, IFactory<T> we should automatically resolve it as a factory.
Then we can remove InstanceProviders, and replace their usages with [Instance] IFactory<T> _instanceProvder;
IInstanceProvider<T>
andIFactory<T>
have identical APIs and it seems pointless keeping them both,Instead if an
[Instance]
field/property or a[Factory]
method returns something of, or inheriting from,IFactory<T>
we should automatically resolve it as a factory.Then we can remove InstanceProviders, and replace their usages with
[Instance] IFactory<T> _instanceProvder;