unity2.0

Unity 2.0: How to use Resolve with ResolverOverride?

谁说我不能喝 提交于 2019-11-28 15:52:14
I started doing more and more work with Unity . I notice that Resolver method takes a params argument ResolverOverride . Can someone give me an example how I can use ResolverOverride or point me some other source where I can get more clues. er-v As you have noticed this is a new (and really cool feature) of the Unity 2. This feature let you pass parameters to constructor in the moment when you resolve the class. In unity 1 you can set only one value in the moment when you register type via new InjectionConstructor(...) There is ParameterOverride : ResolverOverride A ResolverOverride class that

Unity 2.0: How to use Resolve with ResolverOverride?

孤街浪徒 提交于 2019-11-27 09:23:22
问题 I started doing more and more work with Unity. I notice that Resolver method takes a params argument ResolverOverride . Can someone give me an example how I can use ResolverOverride or point me some other source where I can get more clues. 回答1: As you have noticed this is a new (and really cool feature) of the Unity 2. This feature let you pass parameters to constructor in the moment when you resolve the class. In unity 1 you can set only one value in the moment when you register type via new