Start line:  
End line:  

Snippet Preview

Snippet HTML Code

Stack Overflow Questions
Copyright 2011 The Kuali Foundation Licensed under the Educational Community License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.osedu.org/licenses/ECL-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
package org.kuali.student.common.util.krms.proposition;
Parent class for all course completion propositions

Author(s):
alubbers
public abstract class CourseCompletionProposition extends AbstractLeafProposition implements Proposition {
    
    protected final boolean checkForAllCompleted;
    
    protected Integer minToComplete;
            
    public CourseCompletionProposition(Integer minToComplete) {    	
        this. = false;
        this. = minToComplete;
    }
    
    public CourseCompletionProposition() {
         = true;
    }
    
    @Override
    public PropositionResult evaluate(ExecutionEnvironment environment) {
            	
        Collection<StringcompletedCourses = environment.resolveTerm(.this);
        Collection<StringtermCourses = getTermCourseIds(environment);
        PropositionResult result = null;
        if() {
            result = new PropositionResult(completedCourses.containsAll(termCourses));
        }
       
        else {
            result = new PropositionResult(CollectionUtils.intersection(completedCoursestermCourses).size() >= );
        }
        environment.getEngineResults().addResult(new BasicResult(.thisenvironmentresult.getResult()));
        return result;
    
    }
   
    protected abstract Collection<StringgetTermCourseIds(ExecutionEnvironment environment);
    
New to GrepCode? Check out our FAQ X