for (Context context : ((CourseGroup)this.degreeModule).getContextsWithCurricularCourses()) {
for (Context context : ((CourseGroup)this.degreeModule).getSortedContextsWithCurricularCourses()) {
    private List<Double> encodeChildCurricularCourses() throws IOException {        double sumContactLoad = 0.0;        double sumAutonomousWork = 0.0;        double sumTotalLoad = 0.0;        double sumCredits = 0.0;        for (Context context : ((CourseGroup)this.degreeModule).getContextsWithCurricularCourses()) {            DegreeModule degreeModule = context.getDegreeModule();                        sumContactLoad += ((CurricularCourse)degreeModule).getContactLoad(context.getCurricularPeriod().getOrder());            sumAutonomousWork += ((CurricularCourse)degreeModule).getAutonomousWorkHours(context.getCurricularPeriod().getOrder());            sumTotalLoad += ((CurricularCourse)degreeModule).getTotalLoad(context.getCurricularPeriod().getOrder());            sumCredits += degreeModule.getEctsCredits();            new UICurricularCourse(context.getDegreeModule(), context, this.toEdit, this.showRules, this.depth, this.tabs + "\t").encodeBegin(facesContext);        }                List<Double> result = new ArrayList<Double>(4);        result.add(sumContactLoad);        result.add(sumAutonomousWork);        result.add(sumTotalLoad);        result.add(sumCredits);                return result;    }