Class GradebookAssignment

  • All Implemented Interfaces:
    Serializable

    public class GradebookAssignment
    extends GradableObject
    An GradebookAssignment is the basic unit that composes a gradebook. It represents a single unit that, when aggregated in a gradebook, can be used as the denomenator in calculating a CourseGradeRecord.
    Author:
    Josh Holtzman
    See Also:
    Serialized Form
    • Field Detail

      • SORT_BY_DATE

        @Deprecated
        public static String SORT_BY_DATE
        Deprecated.
        use the SortType enum instead. This remains only for the gradebook tool
      • item_type_points

        public static String item_type_points
      • item_type_percentage

        public static String item_type_percentage
      • item_type_letter

        public static String item_type_letter
      • item_type_nonCalc

        public static String item_type_nonCalc
      • item_type_adjustment

        public static String item_type_adjustment
      • dateComparator

        public static Comparator dateComparator
      • nameComparator

        public static Comparator nameComparator
      • pointsComparator

        public static Comparator pointsComparator
      • meanComparator

        public static Comparator meanComparator
      • releasedComparator

        public static Comparator releasedComparator
      • countedComparator

        public static Comparator countedComparator
      • gradeEditorComparator

        public static Comparator gradeEditorComparator
      • categoryComparator

        public static Comparator categoryComparator
      • selectedGradeEntryValue

        public String selectedGradeEntryValue
    • Constructor Detail

      • GradebookAssignment

        public GradebookAssignment()
      • GradebookAssignment

        public GradebookAssignment​(Gradebook gradebook,
                                   String name,
                                   Double pointsPossible,
                                   Date dueDate)
      • GradebookAssignment

        public GradebookAssignment​(Gradebook gradebook,
                                   String name,
                                   Double pointsPossible,
                                   Date dueDate,
                                   boolean released)
        constructor to support selective release
        Parameters:
        gradebook -
        name -
        pointsPossible -
        dueDate -
        released -
    • Method Detail

      • isCourseGrade

        public boolean isCourseGrade()
        Specified by:
        isCourseGrade in class GradableObject
        Returns:
        Whether this gradable object is a course grade
      • isNotCounted

        public boolean isNotCounted()
      • isCounted

        public boolean isCounted()
      • setCounted

        public void setCounted​(boolean counted)
        This cover is for the benefit of JSF checkboxes.
      • isExternallyMaintained

        public boolean isExternallyMaintained()
        Returns:
        Returns the externallyMaintained.
      • isReleased

        public Boolean isReleased()
        Returns:
        selective release true or false
      • calculateStatistics

        public void calculateStatistics​(Collection<AssignmentGradeRecord> gradeRecords)
        Calculate the mean score for students with entered grades.
      • getUngraded

        public boolean getUngraded()
      • getIsExtraCredit

        public Boolean getIsExtraCredit()
      • setIsExtraCredit

        public void setIsExtraCredit​(Boolean isExtraCredit)
      • isExtraCredit

        public Boolean isExtraCredit()
      • getItemType

        public String getItemType()
      • isIncludedInCalculations

        public boolean isIncludedInCalculations()
        Convenience method for checking if the grade for the assignment should be included in calculations. This is different from just the isCounted() method for an assignment. This method does a more thorough check using other values, such as if removed, isExtraCredit, ungraded, etc in addition to the assignment's notCounted property. Now also considers category type. If categories are configured (setting 2 or 3), uncategorised items are not counted.
        Returns:
        true if grades for this assignment should be included in various calculations.
      • isHideInAllGradesTable

        public boolean isHideInAllGradesTable()