internal static void Main()
        {
            var kernel = new StandardKernel();
            kernel.Load(Assembly.GetExecutingAssembly());
            var data = kernel.Get<ICourseData>();

            var courses = new Courses(data);
            courses.PrintAll();
        }
예제 #2
0
        internal static void Main()
        {
            var kernel = new StandardKernel();
            kernel.Load(Assembly.GetExecutingAssembly()); // Loads NinjectModules (code configurations)
            // Easier: this.Bind<ICourseData>().To<CourseData>();

            var data = kernel.Get<ICourseData>();

            var courses = new Courses(data);
            courses.PrintAll();
        }