package users; import java.util.Collection; import grade.*; import course.*; /** * Students have the ability to take and review tests in the Test Tool. Constraints on time limit and account permissions are enforced as the instructor(administrator) sees fit. * Further information on Students can be found in Section 2.1 of the requirements documentation. */ public abstract class Student extends User { /** * A list of all sections of a course that a Student belongs to. */ Collection
sections; /** * The student's grades. */ Grades grades; /** * Default constructor for a Student. * @param id A Student's unique identification * @param realName the Student's given name. */ public Student(String id, String realName) { } /** * Gets the student's grades. * @return the student's grades */ public abstract Grades getGrades(); /** * Adds section to this student * @param s The section being added to the student pre: // the student's section list must not contain s (!sections.contains(s)); post: // the student's section list must contain s // and the section list size must become one larger (sections'.contains(s)) && (sections.size() + 1 == sections'.size()); */ public abstract void addToSection(Section s); /** * Removes a section from this student * @param s The section being removed from the student pre: // the student's section list must contain s (sections.contains(s)); post: // the student's section list must not contain s // and the section list must be one smaller (!sections'.contains(s)) && (sections.size() - 1 == sections'.size()); */ public abstract void removeFromSection(Section s); }