Coverage Report - org.kuali.student.enrollment.class2.acal.service.AcademicCalendarInfoInquiryViewHelperServiceImpl
 
Classes in this File Line Coverage Branch Coverage Complexity
AcademicCalendarInfoInquiryViewHelperServiceImpl
0%
0/16
0%
0/2
4.5
 
 1  
 package org.kuali.student.enrollment.class2.acal.service;
 2  
 
 3  
 import java.util.Map;
 4  
 
 5  
 import javax.xml.namespace.QName;
 6  
 
 7  
 import org.kuali.rice.core.api.resourceloader.GlobalResourceLoader;
 8  
 import org.kuali.rice.krad.inquiry.InquirableImpl;
 9  
 import org.kuali.student.enrollment.acal.service.AcademicCalendarService;
 10  
 import org.kuali.student.enrollment.acal.dto.AcademicCalendarInfo;
 11  
 import org.kuali.student.r2.common.dto.ContextInfo;
 12  
 import org.kuali.student.r2.common.exceptions.DoesNotExistException;
 13  
 import org.kuali.student.r2.common.exceptions.InvalidParameterException;
 14  
 import org.kuali.student.r2.common.exceptions.MissingParameterException;
 15  
 import org.kuali.student.r2.common.exceptions.OperationFailedException;
 16  
 import org.kuali.student.r2.common.exceptions.PermissionDeniedException;
 17  
 
 18  0
 public class AcademicCalendarInfoInquiryViewHelperServiceImpl extends InquirableImpl {
 19  
          public final static String ACADEMIC_CALENDAR_KEY = "key";
 20  
          private transient AcademicCalendarService academicCalendarService;
 21  
          
 22  
     @Override
 23  
     public AcademicCalendarInfo retrieveDataObject(Map<String, String> parameters) {
 24  0
             AcademicCalendarInfo academicCalendarInfo = null;
 25  
             
 26  0
             String academicCalendarKey = parameters.get(ACADEMIC_CALENDAR_KEY);
 27  0
             ContextInfo context = new ContextInfo();
 28  
             try{
 29  0
                     academicCalendarInfo = getAcademicCalendarService().getAcademicCalendar(academicCalendarKey, context);
 30  0
                     return academicCalendarInfo;
 31  0
             }catch (DoesNotExistException dnee){
 32  
                     
 33  0
             }catch (InvalidParameterException ipe){
 34  
                                         
 35  0
             }catch (MissingParameterException mpe){
 36  
                     
 37  0
             }catch (OperationFailedException ofe){
 38  
                     
 39  0
             }catch (PermissionDeniedException pde){
 40  
                     
 41  0
             }
 42  0
             return null;
 43  
 
 44  
     }
 45  
     
 46  
     protected AcademicCalendarService getAcademicCalendarService() {
 47  0
         if(academicCalendarService == null) {
 48  0
                 academicCalendarService = (AcademicCalendarService) GlobalResourceLoader.getService(new QName("http://student.kuali.org/wsdl/acal","AcademicCalendarService"));
 49  
        }
 50  
 
 51  0
        return academicCalendarService;
 52  
    }
 53  
 
 54  
 
 55  
 }
 56