org.sakaiproject.tool.gradebook
Class Assignment
java.lang.Object
org.sakaiproject.tool.gradebook.GradableObject
org.sakaiproject.tool.gradebook.Assignment
- All Implemented Interfaces:
- Serializable
public class Assignment
- extends GradableObject
An Assignment 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
| Fields inherited from class org.sakaiproject.tool.gradebook.GradableObject |
categoryComparator, defaultComparator, gradebook, id, idComparator, log, mean, name, removed, sortingComparator, sortOrder, version |
| Methods inherited from class org.sakaiproject.tool.gradebook.GradableObject |
assignSorting, equals, getFormattedMean, getGradebook, getId, getMean, getName, getSortOrder, getSortPosition, getVersion, hashCode, isFirst, isLast, isRemoved, setGradebook, setId, setMean, setName, setRemoved, setSortOrder, setVersion, toString |
SORT_BY_DATE
public static String SORT_BY_DATE
SORT_BY_NAME
public static String SORT_BY_NAME
SORT_BY_MEAN
public static String SORT_BY_MEAN
SORT_BY_POINTS
public static String SORT_BY_POINTS
SORT_BY_RELEASED
public static String SORT_BY_RELEASED
SORT_BY_COUNTED
public static String SORT_BY_COUNTED
SORT_BY_EDITOR
public static String SORT_BY_EDITOR
SORT_BY_SORTING
public static String SORT_BY_SORTING
DEFAULT_SORT
public static String DEFAULT_SORT
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
selectedGradeEntryValue
public String selectedGradeEntryValue
Assignment
public Assignment(Gradebook gradebook,
String name,
Double pointsPossible,
Date dueDate)
Assignment
public Assignment(Gradebook gradebook,
String name,
Double pointsPossible,
Date dueDate,
boolean released)
- constructor to support selective release
- Parameters:
gradebook - name - pointsPossible - dueDate - released -
Assignment
public Assignment()
isCourseGrade
public boolean isCourseGrade()
- Specified by:
isCourseGrade in class GradableObject
- Returns:
- Whether this gradable object is a course grade
isAssignment
public boolean isAssignment()
- Specified by:
isAssignment in class GradableObject
- Returns:
- Whether this gradable object is an assignment
- See Also:
GradableObject.isAssignment()
getIsCategory
public boolean getIsCategory()
- Specified by:
getIsCategory in class GradableObject
- Returns:
- Whether this gradable object is a category
- See Also:
org.sakaiproject.tool.gradebook.GradableObject#isCategory()
getDateForDisplay
public Date getDateForDisplay()
getDueDate
public Date getDueDate()
- Returns:
- Returns the dueDate.
setDueDate
public void setDueDate(Date dueDate)
- Parameters:
dueDate - The dueDate to set.
isNotCounted
public boolean isNotCounted()
setNotCounted
public void setNotCounted(boolean notCounted)
isCounted
public boolean isCounted()
setCounted
public void setCounted(boolean counted)
- This cover is for the benefit of JSF checkboxes.
getExternalInstructorLink
public String getExternalInstructorLink()
- Returns:
- Returns the externalInstructorLink.
setExternalInstructorLink
public void setExternalInstructorLink(String externalInstructorLink)
- Parameters:
externalInstructorLink - The externalInstructorLink to set.
isExternallyMaintained
public boolean isExternallyMaintained()
- Returns:
- Returns the externallyMaintained.
setExternallyMaintained
public void setExternallyMaintained(boolean externallyMaintained)
- Parameters:
externallyMaintained - The externallyMaintained to set.
getExternalStudentLink
public String getExternalStudentLink()
- Returns:
- Returns the externalStudentLink.
setExternalStudentLink
public void setExternalStudentLink(String externalStudentLink)
- Parameters:
externalStudentLink - The externalStudentLink to set.
getPointsPossible
public Double getPointsPossible()
- Returns:
- Returns the pointsPossible.
setPointsPossible
public void setPointsPossible(Double pointsPossible)
- Parameters:
pointsPossible - The pointsPossible to set.
getExternalId
public String getExternalId()
- Returns:
- Returns the externalId.
setExternalId
public void setExternalId(String externalId)
- Parameters:
externalId - The externalId to set.
getExternalAppName
public String getExternalAppName()
- Returns:
- Returns the externalAppName.
setExternalAppName
public void setExternalAppName(String externalAppName)
- Parameters:
externalAppName - The externalAppName to set.
isReleased
public boolean isReleased()
- Returns:
- selective release true or false
setReleased
public void setReleased(boolean released)
- Parameters:
released - returns wther the assignment has been released to users
calculateStatistics
public void calculateStatistics(Collection<AssignmentGradeRecord> gradeRecords)
- Calculate the mean score for students with entered grades.
getCategory
public Category getCategory()
setCategory
public void setCategory(Category category)
getAverageTotal
public Double getAverageTotal()
setAverageTotal
public void setAverageTotal(Double averageTotal)
getUngraded
public boolean getUngraded()
setUngraded
public void setUngraded(boolean ungraded)
isExtraCredit
public Boolean isExtraCredit()
setExtraCredit
public void setExtraCredit(Boolean isExtraCredit)
getAssignmentWeighting
public Double getAssignmentWeighting()
setAssignmentWeighting
public void setAssignmentWeighting(Double assignmentWeighting)
getItemType
public String getItemType()
setItemType
public void setItemType(String itemType)
getCountNullsAsZeros
public Boolean getCountNullsAsZeros()
setCountNullsAsZeros
public void setCountNullsAsZeros(Boolean countNullsAsZeros)
getSelectedGradeEntryValue
public String getSelectedGradeEntryValue()
setSelectedGradeEntryValue
public void setSelectedGradeEntryValue(String selectedGradeEntryValue)
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.
- Returns:
- true if grades for this assignment should be included in various calculations.
isHideInAllGradesTable
public boolean isHideInAllGradesTable()
setHideInAllGradesTable
public void setHideInAllGradesTable(boolean hideInAllGradesTable)
Copyright © 2003-2013 Sakai Project. All Rights Reserved.