ninject
Ninject Contextual Binding Based on Method's Parameter Value
I am attempting to use ninjects contextual binding functionality to bind to the correct implementation of an interface based on the value of an enum parameter passed into a method, and I\'m stuck. I t[详细]
2023-04-11 04:32 分类:问答Moq with constructor argument
I have a factory that looks like below: public IFoo GetFoo(IFile file开发者_Go百科) { return _kernel.Get<IFoo>(new ConstructorArgument(\"file\", file));[详细]
2023-04-10 17:22 分类:问答Autofac equivalent of Ninject's WhenInjectedInto()
So we\'re working on converting some projects at work from Ninject to Autofac, and we\'ve stumbled on something really neat within Ninject that we can\'t figure out how to do in Autofac.In our applica[详细]
2023-04-10 17:21 分类:问答Ninject getting a generic type in ToMethod
I have a repository like this: public class Repository<T> : IRepository<T> where T : class[详细]
2023-04-10 13:41 分类:问答Ninject - Kernel in static class?
Is it right at all to \"wrap\" a StandardKernel with the required NinjectModules in a static class in a separate, share开发者_运维知识库d library, and use that same library whenever injection is neede[详细]
2023-04-09 19:40 分类:问答EntityFramework Repositories drives from an Interface and abstract class : how to use dependency inject on ASP.NET MVC
Ok, let me break down what I have been trying to do : First of all here is the abstract generic repository of mine :[详细]
2023-04-09 08:53 分类:问答Ninject MVC Controller from external assembly
I have some controllers in an external assembly, such as: namespace SomeExternalAssembly.Controllers { public class SomeExternalController : Controller[详细]
2023-04-09 02:52 分类:问答ninject and enterprise library service locator dependant assemblies
I am using the Microsoft.Practices.ServiceLocation assembly in conjunction with ninject to aid in service loaction. I register my ninject kernel into the servicelocator provider method:[详细]
2023-04-09 02:11 分类:问答Asp Mvc 3 with NinjectHttpApplication and MEF
I am using Ninject as my MVC contr开发者_高级运维oller factory, but I also load in certain routes and controllers via MEF, these controllers need to be able to register themselves with Ninject:[详细]
2023-04-08 23:50 分类:问答Ninject.Web.Mvc knows about dynamically loaded Controller but ASP.Mvc doesnt?
I have got quite a complex project on the go at the moment, and as part of this I have a MEF layer which purely handles loading of plugins and then the newly loaded plugins expose their routes which a[详细]
2023-04-08 12:03 分类:问答