private static void RegisterServices(IKernel kernel) { kernel.Bind<SampleContext>().ToSelf().InRequestScope(); kernel.Bind<IUnitOfWork>().To<UnitOfWork>(); kernel.Bind(typeof(IGenericRepository<>)).To(typeof(GenericRepository<>)); } }