simpleinjector / SimpleInjector

An easy, flexible, and fast Dependency Injection library that promotes best practice to steer developers towards the pit of success.
https://simpleinjector.org
MIT License
1.21k stars 154 forks source link

Add InstanceProducer.GetInstance(Scope) overload #947

Closed dotnetjunkie closed 2 years ago

dotnetjunkie commented 2 years ago

In the of the use of flowing scopes, the InstanceProducer classes can't be used; they under the covers resolve from the ambient scope, which isn't available when flowing scopes with the composed object graphs. A new GetInstance(Scope) method would solve this.