Skip to content

Commit

Permalink
[+] Create copy constructor in Course class
Browse files Browse the repository at this point in the history
  • Loading branch information
hykilpikonna committed Sep 7, 2019
1 parent 90bf0b2 commit b278834
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions src/main/java/org/hydev/veracross/sdk/model/VeracrossCourse.java
Original file line number Diff line number Diff line change
Expand Up @@ -34,4 +34,15 @@ public class VeracrossCourse implements VeracrossData

// Numeric grade (nullable)
private Double numericGrade;

/**
* Self-constructor that copies all field from the other
*
* @param other Other
*/
public VeracrossCourse(VeracrossCourse other)
{
this(other.name, other.teacherName, other.id, other.assignmentsId,
other.letterGrade, other.numericGrade);
}
}

0 comments on commit b278834

Please sign in to comment.