bool WriteCourse(Id <Course> courseId, int courseNumber) { // A course must have a start and a finish to be output. if (!QueryEvent.HasStartControl(eventDB, courseId)) { return(false); } if (!QueryEvent.HasFinishControl(eventDB, courseId)) { return(false); } Course course = eventDB.GetCourse(courseId); bool isScore = (course.kind == CourseKind.Score); string[] classNames = GetClassNames(eventDB, courseId); CourseView courseView = CourseView.CreateViewingCourseView(eventDB, new CourseDesignator(courseId)); WriteCourseGroupStart(course.name, courseNumber, classNames, isScore); WriteCourseVariations(courseId, course.name, courseNumber, classNames, isScore); WriteCourseGroupEnd(); return(true); }