Package edu.pdx.cs410J.grader.gradebook
Class GradeBook
java.lang.Object
edu.pdx.cs410J.grader.gradebook.GradeBook
This class represents a grade book that contains information about
a CS410J class: the assignments, the students and their grades.
- Since:
- Fall 2000
- Author:
- David Whitlock
-
Nested Class Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionaddAssignment
(Assignment assignment) Adds anAssignment
to this classaddStudent
(Student student) Adds aStudent
to thisGradeBook
boolean
Returns whether or not this grade book contains a student with the given id.void
forEachStudent
(Consumer<Student> consumer) getAssignment
(String name) Returns theAssignment
of a given nameReturns the names of the assignments for this classReturns the name of the class represented by thisGradeBook
int
getCRN()
Returns the Course Request Number (CRN) for this grade book.getLetterGradeForScore
(Student.Section section, double score) getLetterGradeRanges
(Student.Section section) getSectionName
(Student.Section section) getStudent
(String id) Returns the ids of all the students in this classboolean
isDirty()
Returnstrue
if thisGradeBook
has been modified.static void
Main program that is used to create aGradeBook
void
Marks thisGradeBook
as being cleanvoid
removeStudent
(Student student) Removes aStudent
from thisGradeBook
void
setCRN
(int crn) Sets the Course Request Number (CRN) for this grade book.void
setDirty
(boolean dirty) Sets the dirtiness of thisGradeBook
void
setSectionName
(Student.Section section, String sectionName) toString()
Returns a brief textual description of thisGradeBook
.
-
Constructor Details
-
GradeBook
Creates a newGradeBook
for a given class
-
-
Method Details
-
getSections
-
getClassName
Returns the name of the class represented by thisGradeBook
-
getAssignmentNames
Returns the names of the assignments for this class -
setCRN
Sets the Course Request Number (CRN) for this grade book.- Since:
- Spring 2005
-
getCRN
Returns the Course Request Number (CRN) for this grade book.- Since:
- Spring 2005
-
getAssignment
Returns theAssignment
of a given name -
addAssignment
Adds anAssignment
to this class- Returns:
assignment
so that method calls can be chained
-
getStudentIds
Returns the ids of all the students in this class -
getStudent
-
studentsStream
-
addStudent
Adds aStudent
to thisGradeBook
- Returns:
student
so that calls can be chained- See Also:
-
removeStudent
Removes aStudent
from thisGradeBook
-
containsStudent
Returns whether or not this grade book contains a student with the given id. -
setDirty
Sets the dirtiness of thisGradeBook
-
makeClean
Marks thisGradeBook
as being clean -
isDirty
Returnstrue
if thisGradeBook
has been modified. -
toString
Returns a brief textual description of thisGradeBook
. -
main
Main program that is used to create aGradeBook
-
getLetterGradeRanges
-
getLetterGradeForScore
-
forEachStudent
-
assignmentsStream
-
getSectionName
-
setSectionName
-