if (studentCurricularPlan.getSpecialization().equals(Specialization.MASTER_DEGREE)) {
if (studentCurricularPlan.getSpecialization().equals(Specialization.STUDENT_CURRICULAR_PLAN_MASTER_DEGREE)) {
    public Collection run(String executionYearName) throws ExcepcaoPersistencia {        final ExecutionYear executionYear = ExecutionYear.readExecutionYearByName(executionYearName);        final Collection<InfoStudentCurricularPlanWithFirstTimeEnrolment> infoStudentCurricularPlans = new ArrayList();        final Collection<StudentCurricularPlan> studentCurricularPlans = new ArrayList();        final Collection<DegreeCurricularPlan> masterDegreeCurricularPlans = DegreeCurricularPlan.readByDegreeTypeAndState(DegreeType.MASTER_DEGREE, DegreeCurricularPlanState.ACTIVE);        CollectionUtils.filter(masterDegreeCurricularPlans, new Predicate() {            public boolean evaluate(Object arg0) {                DegreeCurricularPlan degreeCurricularPlan = (DegreeCurricularPlan) arg0;                for (ExecutionDegree executionDegree : degreeCurricularPlan.getExecutionDegrees()) {                    if (executionDegree.getExecutionYear().equals(executionYear)) {                        return true;                    }                }                return false;            }        });        for (DegreeCurricularPlan degreeCurricularPlan : masterDegreeCurricularPlans) {            studentCurricularPlans.addAll(degreeCurricularPlan.getStudentCurricularPlans());        }        for (StudentCurricularPlan studentCurricularPlan : studentCurricularPlans) {            if (!studentCurricularPlan.getCurrentState().equals(StudentCurricularPlanState.ACTIVE)                    && !studentCurricularPlan.getCurrentState().equals(                            StudentCurricularPlanState.SCHOOLPARTCONCLUDED)) {                continue;            }            boolean firstTimeEnrolment = true;            if (studentCurricularPlan.getSpecialization().equals(Specialization.MASTER_DEGREE)) {            	Collection<StudentCurricularPlan> previousStudentCurricularPlans = studentCurricularPlan.getStudent().getStudentCurricularPlansBySpecialization(Specialization.MASTER_DEGREE);                previousStudentCurricularPlans.remove(studentCurricularPlan);                for (StudentCurricularPlan previousStudentCurricularPlan : previousStudentCurricularPlans) {                    if (previousStudentCurricularPlan.getDegreeCurricularPlan().getDegree().equals(                            studentCurricularPlan.getDegreeCurricularPlan().getDegree())) {                        firstTimeEnrolment = false;                        break;                    }                }            } else if (studentCurricularPlan.getSpecialization().equals(Specialization.SPECIALIZATION)) {                if (!getFirstExecutionDegree(studentCurricularPlan.getDegreeCurricularPlan())                        .getExecutionYear().equals(executionYear)) {                    continue;                }            }            if (firstTimeEnrolment) {                if (!getFirstExecutionDegree(studentCurricularPlan.getDegreeCurricularPlan())                        .getExecutionYear().equals(executionYear)) {                    firstTimeEnrolment = false;                }            }            InfoStudentCurricularPlanWithFirstTimeEnrolment infoStudentCurricularPlan = InfoStudentCurricularPlanWithFirstTimeEnrolment                    .newInfoFromDomain(studentCurricularPlan);            infoStudentCurricularPlan.setFirstTimeEnrolment(firstTimeEnrolment);            infoStudentCurricularPlans.add(infoStudentCurricularPlan);        }        return infoStudentCurricularPlans;    }