Package org.fenixedu.academic.domain.curricularRules

Examples of org.fenixedu.academic.domain.curricularRules.MaximumNumberOfEctsInStandaloneCurriculumGroup


        if (actualResult.isFalse()) {
            return actualResult;
        }

        if (isEmptyDegree()) {
            return actualResult.and(new MaximumNumberOfEctsInStandaloneCurriculumGroup(getStandaloneCurriculumGroup()).evaluate(
                    getEnroledCurriculumGroup(), enrolmentContext));
        } else {
            return actualResult;
        }
    }
View Full Code Here


    @Override
    protected RuleResult executeEnrolmentVerificationWithRules(final ICurricularRule curricularRule,
            final IDegreeModuleToEvaluate sourceDegreeModuleToEvaluate, final EnrolmentContext enrolmentContext) {

        final MaximumNumberOfEctsInStandaloneCurriculumGroup rule =
                (MaximumNumberOfEctsInStandaloneCurriculumGroup) curricularRule;
        final double total = calculateTotalEctsCredits(enrolmentContext) + calculateApprovedEcts(enrolmentContext);
        if (!rule.allowEcts(total)) {
            return RuleResult.createFalse(sourceDegreeModuleToEvaluate.getDegreeModule(),
                    "curricularRules.ruleExecutors.MaximumNumberOfEctsInStandaloneCurriculumGroupExecutor",
                    String.valueOf(rule.getMaximumEcts()), String.valueOf(total));
        }

        return RuleResult.createTrue(sourceDegreeModuleToEvaluate.getDegreeModule());
    }
View Full Code Here

TOP

Related Classes of org.fenixedu.academic.domain.curricularRules.MaximumNumberOfEctsInStandaloneCurriculumGroup

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.