Class CourseGrade
- java.lang.Object
-
- org.sakaiproject.service.gradebook.shared.CourseGrade
-
- All Implemented Interfaces:
Serializable
public class CourseGrade extends Object implements Serializable
Wrapper for the course grade that contains the the calculated grade (ie 46.67), the mapped grade (ie F) and any entered grade override (ie D-).- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description CourseGrade()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description StringgetCalculatedGrade()DategetDateRecorded()StringgetDisplayGrade()Helper to get a grade override preferentially, or fallback to the standard mapped grade.StringgetEnteredGrade()DoublegetEnteredPoints()LonggetId()ID of this course grade record.StringgetMappedGrade()DoublegetPointsEarned()DoublegetTotalPointsPossible()This value is only accurate when there are no weighted categories.voidsetCalculatedGrade(String calculatedGrade)voidsetDateRecorded(Date dateRecorded)voidsetEnteredGrade(String enteredGrade)voidsetEnteredPoints(Double enteredPoints)voidsetId(Long id)voidsetMappedGrade(String mappedGrade)voidsetPointsEarned(Double pointsEarned)voidsetTotalPointsPossible(Double totalPointsPossible)StringtoString()
-
-
-
Method Detail
-
getId
public Long getId()
ID of this course grade record. This will be null if the course grade is calculated, and non null if we have an override (as it then refers to the course grade assignment id).- Returns:
-
setId
public void setId(Long id)
-
getEnteredGrade
public String getEnteredGrade()
-
setEnteredGrade
public void setEnteredGrade(String enteredGrade)
-
getEnteredPoints
public Double getEnteredPoints()
-
setEnteredPoints
public void setEnteredPoints(Double enteredPoints)
-
getCalculatedGrade
public String getCalculatedGrade()
-
setCalculatedGrade
public void setCalculatedGrade(String calculatedGrade)
-
getMappedGrade
public String getMappedGrade()
-
setMappedGrade
public void setMappedGrade(String mappedGrade)
-
getPointsEarned
public Double getPointsEarned()
-
setPointsEarned
public void setPointsEarned(Double pointsEarned)
-
getTotalPointsPossible
public Double getTotalPointsPossible()
This value is only accurate when there are no weighted categories. If weighting is enabled, this value will not be what you expect. For this reason, this value should not be used when weighted categories are enabled.- Returns:
- Double representing the total points possible, see caveat.
-
setTotalPointsPossible
public void setTotalPointsPossible(Double totalPointsPossible)
-
getDateRecorded
public Date getDateRecorded()
-
setDateRecorded
public void setDateRecorded(Date dateRecorded)
-
getDisplayGrade
public String getDisplayGrade()
Helper to get a grade override preferentially, or fallback to the standard mapped grade.- Returns:
-
-