Ejemplo n.º 1
0
        public void EnrolInstructorToCourse(int courseID, int instructorID)
        {
            // check if course exists
            ICourseRepository courseRepo = new CourseRepository();

            if (!courseRepo.IsCourseExist(courseID))
            {
                // course not exists
                throw new CourseNotFondException(courseID + " is not a registered  course.");
            }

            courseRepo.EnrolInstructorToCourse(courseID, instructorID);
        }