public static void OrderAndTake(string courseName, string comparison, int?studentsToTake = null) { if (studentsToTake == null) { studentsToTake = studentsByCourse[courseName].Count; } RepositorySorters.OrderAndTake(studentsByCourse[courseName], comparison, studentsToTake.Value); }
public static void OrderAndTake(string course, string comparison, int?studentsToTake = null) { if (IsQueryForCoursePossible(course)) { if (studentsToTake == null) { studentsToTake = studentsByCourse[course].Count; } RepositorySorters.OrderAndTake(studentsByCourse[course], comparison, studentsToTake.Value); } }
public static void OrderAndTake(string courseName, string givenFilter, int?studentsToTake = null) { if (IsQueryForCoursePossible(courseName)) { if (studentsToTake == null) { studentsToTake = studentsByCourse[courseName].Count; } RepositorySorters.OrderAndTake(studentsByCourse[courseName], givenFilter, studentsToTake.Value); } }
// Constructor for the current class which recieves a RepositorySorter and a RepositoryFilter as parameters public StudentsRepository(RepositoryFilters filter, RepositorySorters sorter) { this.filter = filter; this.sorter = sorter; }
public StudentsRepository(RepositoryFilter repositoryFilter, RepositorySorters repositorySorters) { this.repositoryFilter = repositoryFilter; this.repositorySorters = repositorySorters; }