private static void TryShowWantedData(string input, string[] data) { if (data.Length == 2) { string courseName = data[1]; StudentsRepository.GetAllStudentsFromCourse(courseName); } else if (data.Length == 3) { string courseName = data[1]; string userName = data[2]; StudentsRepository.GetStudentScoresFromCourse(courseName, userName); } else { DisplayInvalidCommandMessage(input); } }
private static void TryShowWantedData(string input, string[] data) { if (data.Length == 2) { string courseName = data[1]; StudentsRepository.GetAllStudentsFromCourse(courseName); } else if (data.Length == 3) { string courseName = data[1]; string studentName = data[2]; StudentsRepository.GetStudentScoresFromCourse(courseName, studentName); } else { OutputWriter.DisplayExeptions(ExceptionMessages.InvalidCommandMessage(input)); } }