Mhotivo.NinjectWebCommon.CreateKernel C# (CSharp) Méthode

CreateKernel() private static méthode

Creates the kernel that will manage your application.
private static CreateKernel ( ) : IKernel
Résultat IKernel
        private static IKernel CreateKernel()
        {
            var kernel = new StandardKernel();
            try
            {
                kernel.Bind<Func<IKernel>>().ToMethod(ctx => () => new Bootstrapper().Kernel);
                kernel.Bind<IHttpModule>().To<HttpApplicationInitializationHttpModule>();
                RegisterServices(kernel);
                return kernel;
            }
            catch
            {
                kernel.Dispose();
                throw;
            }
        }