Package org.dnsge.powerschoolapi.detail
Class GradeGroup
- java.lang.Object
-
- org.dnsge.powerschoolapi.detail.GradeGroup
-
public class GradeGroup extends java.lang.ObjectClass that represents a group of grades- Version:
- 1.0.3
-
-
Constructor Summary
Constructors Constructor Description GradeGroup(DocumentFetcher documentFetcher, java.lang.String letterGrade, float numberGrade, ColumnMode gradingPeriod, java.lang.String hrefAttrib)General constructorGradeGroup(DocumentFetcher documentFetcher, ColumnMode gradingPeriod)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static GradeGroupemptyGrade(Course myCourse, ColumnMode gradingPeriod)Creates a new GradeGroup that is 'empty' and 'unused'booleanequals(java.lang.Object o)GradingPeriodgetGradingPeriod()java.lang.StringgetGradingPeriodName()java.lang.StringgetHrefAttrib()java.lang.StringgetLetterGrade()floatgetNumberGrade()inthashCode()booleanisEmpty()booleanisUnused()static GradeGroupnoGrade(Course myCourse, ColumnMode gradingPeriod)Creates a new GradeGroup that is 'empty'voidsetEmpty(boolean empty)voidsetUnused(boolean unused)java.lang.StringtoString()
-
-
-
Constructor Detail
-
GradeGroup
public GradeGroup(DocumentFetcher documentFetcher, java.lang.String letterGrade, float numberGrade, ColumnMode gradingPeriod, java.lang.String hrefAttrib)
General constructor- Parameters:
documentFetcher-DocumentFetcherto use for getting detailed assignmentsletterGrade- Grade as a letter for GradeGroupnumberGrade- Grade as a number for GradeGroupgradingPeriod- Period of Grading (Whole year, quarter 1, ect)hrefAttrib- Partial URL that contains a link to the page for the assignments within this specific GradeGroup
-
GradeGroup
public GradeGroup(DocumentFetcher documentFetcher, ColumnMode gradingPeriod)
-
-
Method Detail
-
noGrade
public static GradeGroup noGrade(Course myCourse, ColumnMode gradingPeriod)
Creates a new GradeGroup that is 'empty'- Parameters:
myCourse-Coursethat the GradeGroup belongs togradingPeriod- Period of Grading (Whole year, quarter 1, ect)- Returns:
- new GradeGroup object with the desired attributes
-
emptyGrade
public static GradeGroup emptyGrade(Course myCourse, ColumnMode gradingPeriod)
Creates a new GradeGroup that is 'empty' and 'unused'- Parameters:
myCourse-Coursethat the GradeGroup belongs togradingPeriod- Period of Grading (Whole year, quarter 1, ect)- Returns:
- new GradeGroup object with the desired attributes
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
equals
public boolean equals(java.lang.Object o)
- Overrides:
equalsin classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCodein classjava.lang.Object
-
isEmpty
public boolean isEmpty()
- Returns:
- Whether this
GradeGrouphas no grades
-
setEmpty
public void setEmpty(boolean empty)
- Parameters:
empty- Whether thisGradeGrouphas no grades
-
setUnused
public void setUnused(boolean unused)
-
getLetterGrade
public java.lang.String getLetterGrade()
- Returns:
GradeGroupletter grade
-
getNumberGrade
public float getNumberGrade()
- Returns:
GradeGroupgrade as a decimal out of 100
-
getGradingPeriod
public GradingPeriod getGradingPeriod()
- Returns:
- The
GradingPeriodof thisGradeGroup - See Also:
GradingPeriod
-
getGradingPeriodName
public java.lang.String getGradingPeriodName()
- Returns:
- The name of the grading period of this
GradeGroup
-
getHrefAttrib
public java.lang.String getHrefAttrib()
- Returns:
- The href attribute of the
Elementused to make this GradeGroup
-
isUnused
public boolean isUnused()
-
-