I want to use ninject (version 4.0.0) to resolve dependencies in my Windows Service program, I have seen quite a few tutorials, and they all use StandardKernel to initialize ninject Kernel as below:
IKernel kernel = new StandardKernel();
kernel.Load(Assembly.GetExecutingAssembly());
But I am getting the following warning when using StandardKernel:
'StandardKernel' is obsolete: 'Use StandardKernelConfiguration and StandardReadonlyKernel'
Can anyone give an example using StandardKernelConfiguration and StandardReadonlyKernel?