Coverage Report - org.mule.module.xml.config.JaxbContextFactoryBean
 
Classes in this File Line Coverage Branch Coverage Complexity
JaxbContextFactoryBean
0%
0/11
0%
0/2
0
 
 1  
 /*
 2  
  * Copyright (c) MuleSoft, Inc.  All rights reserved.  http://www.mulesoft.com
 3  
  * The software in this package is published under the terms of the CPAL v1.0
 4  
  * license, a copy of which has been included with this distribution in the
 5  
  * LICENSE.txt file.
 6  
  */
 7  
 package org.mule.module.xml.config;
 8  
 
 9  
 import org.mule.config.i18n.CoreMessages;
 10  
 
 11  
 import javax.xml.bind.JAXBContext;
 12  
 
 13  
 import org.springframework.beans.factory.config.AbstractFactoryBean;
 14  
 
 15  
 /**
 16  
  * TODO
 17  
  */
 18  0
 public class JaxbContextFactoryBean extends AbstractFactoryBean
 19  
 {
 20  
     private String packageNames;
 21  
     private String name;
 22  
 
 23  
     @Override
 24  
     public Class getObjectType()
 25  
     {
 26  0
         return JAXBContext.class;
 27  
     }
 28  
 
 29  
     @Override
 30  
     protected Object createInstance() throws Exception
 31  
     {
 32  0
         if(packageNames==null)
 33  
         {
 34  0
             throw new IllegalArgumentException(CoreMessages.objectIsNull("packageNames").getMessage());
 35  
         }
 36  0
         return JAXBContext.newInstance(packageNames);
 37  
     }
 38  
 
 39  
     public String getPackageNames()
 40  
     {
 41  0
         return packageNames;
 42  
     }
 43  
 
 44  
     public void setPackageNames(String packageNames)
 45  
     {
 46  0
         this.packageNames = packageNames;
 47  0
     }
 48  
 
 49  
     public String getName()
 50  
     {
 51  0
         return name;
 52  
     }
 53  
 
 54  
     public void setName(String name)
 55  
     {
 56  0
         this.name = name;
 57  0
     }
 58  
 }