Coverage Report - org.kuali.student.enrollment.class2.registration.dto.CourseOfferingWrapper
 
Classes in this File Line Coverage Branch Coverage Complexity
CourseOfferingWrapper
0%
0/19
0%
0/10
1.625
 
 1  
 package org.kuali.student.enrollment.class2.registration.dto;
 2  
 
 3  
 import org.apache.commons.lang.StringUtils;
 4  
 import org.kuali.student.enrollment.courseoffering.dto.CourseOfferingInfo;
 5  
 import org.kuali.student.enrollment.courseoffering.dto.OfferingInstructorInfo;
 6  
 
 7  
 import java.io.Serializable;
 8  
 import java.util.ArrayList;
 9  
 import java.util.List;
 10  
 
 11  
 public class CourseOfferingWrapper implements Serializable {
 12  
     private static final long serialVersionUID = 1L;
 13  
 
 14  
     private CourseOfferingInfo courseOffering;
 15  
     private String prereq;
 16  
 
 17  
     private List<RegistrationGroupWrapper> registrationGroupWrappers;
 18  
 
 19  0
     public CourseOfferingWrapper() {
 20  0
         registrationGroupWrappers = new ArrayList<RegistrationGroupWrapper>();
 21  0
     }
 22  
 
 23  
     public List<RegistrationGroupWrapper> getRegistrationGroupWrappers() {
 24  0
         return registrationGroupWrappers;
 25  
     }
 26  
 
 27  
     public void setRegistrationGroupWrappers(List<RegistrationGroupWrapper> registrationGroupWrappers) {
 28  0
         this.registrationGroupWrappers = registrationGroupWrappers;
 29  0
     }
 30  
 
 31  
     public CourseOfferingInfo getCourseOffering() {
 32  0
         return courseOffering;
 33  
     }
 34  
 
 35  
     public void setCourseOffering(CourseOfferingInfo courseOffering) {
 36  0
         this.courseOffering = courseOffering;
 37  0
     }
 38  
 
 39  
     public String getInstructorsList(){
 40  0
         String instructors = "";
 41  0
         if(this.getCourseOffering() != null && this.getCourseOffering().getInstructors() != null &&
 42  
                 !this.getCourseOffering().getInstructors().isEmpty()){
 43  0
             for(OfferingInstructorInfo instructor: this.getCourseOffering().getInstructors()){
 44  0
                 if(StringUtils.isBlank(instructors)){
 45  0
                     instructors = instructor.getPersonId();
 46  
                 }
 47  
                 else{
 48  0
                     instructors = instructor + ", " + instructor.getPersonId();
 49  
                 }
 50  
             }
 51  
         }
 52  0
         return instructors;
 53  
     }
 54  
 
 55  
     public String getPrereq() {
 56  0
         return prereq;
 57  
     }
 58  
 
 59  
     public void setPrereq(String prereq) {
 60  0
         this.prereq = prereq;
 61  0
     }
 62  
 }