Mugen Injection [Special parameters]
All methods to resolve accepts special-parameters. Why do they need, sometimes we need to pass some information and we do not want to create another class for the description parameter. In this case you can use special-parameters.
This code shows how it works:
// Create your MugenInjector. _injector = new MugenInjector(); _injector.Bind<IRepository>() .ToMethod<IRepository>(context => { if (context.SpecialParameters.ContainsKey("fake")) return new FakeRepository(); return new Repository(); }); _injector.Get<IRepository>(new Dictionary<string, object>() {{"fake", true}});