Filter faculties by specialty

This commit is contained in:
2023-10-03 01:27:05 +03:00
parent d5a7a2c460
commit 4461b1137a
13 changed files with 177 additions and 32 deletions

View File

@@ -21,4 +21,24 @@ public class StudentManager implements Serializable {
students.remove(student);
}
// public List<Student> getGraduates() {
// List<Student> stList = new ArrayList<>();
// for (Student st : students) {
// if (st.isGraduated()) {
// stList.add(st);
// }
// }
// return stList;
// }
public List<Student> getEnrolled() {
List<Student> stList = new ArrayList<>();
for (Student st : students) {
if (!st.isGraduated()) {
stList.add(st);
}
}
return stList;
}
}