Coverage Report - org.kuali.rice.core.api.util.jaxb.StringMapEntryList
 
Classes in this File Line Coverage Branch Coverage Complexity
StringMapEntryList
90%
9/10
50%
1/2
1.667
 
 1  
 /*
 2  
  * Copyright 2007-2009 The Kuali Foundation
 3  
  *
 4  
  * Licensed under the Educational Community License, Version 2.0 (the "License");
 5  
  * you may not use this file except in compliance with the License.
 6  
  * You may obtain a copy of the License at
 7  
  *
 8  
  * http://www.opensource.org/licenses/ecl2.php
 9  
  *
 10  
  * Unless required by applicable law or agreed to in writing, software
 11  
  * distributed under the License is distributed on an "AS IS" BASIS,
 12  
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 13  
  * See the License for the specific language governing permissions and
 14  
  * limitations under the License.
 15  
  */
 16  
 package org.kuali.rice.core.api.util.jaxb;
 17  
 
 18  
 import org.kuali.rice.core.api.mo.AbstractDataTransferObject;
 19  
 import org.w3c.dom.Element;
 20  
 
 21  
 import javax.xml.bind.annotation.XmlAccessType;
 22  
 import javax.xml.bind.annotation.XmlAccessorType;
 23  
 import javax.xml.bind.annotation.XmlAnyElement;
 24  
 import javax.xml.bind.annotation.XmlElement;
 25  
 import javax.xml.bind.annotation.XmlType;
 26  
 import java.util.ArrayList;
 27  
 import java.util.Collection;
 28  
 import java.util.Collections;
 29  
 import java.util.List;
 30  
 
 31  
 @XmlAccessorType(XmlAccessType.FIELD)
 32  
 @XmlType(name = "StringMapEntryListType")
 33  
 public class StringMapEntryList extends AbstractDataTransferObject {
 34  
 
 35  
         private static final long serialVersionUID = 1L;
 36  
 
 37  
         @XmlElement(name = "entry")
 38  
         private final List<StringMapEntry> entries;
 39  
 
 40  39
     @SuppressWarnings("unused")
 41  
     @XmlAnyElement
 42  
     private final Collection<Element> _futureElements = null;
 43  
 
 44  
         @SuppressWarnings("unused")
 45  25
         private StringMapEntryList() {
 46  25
                 this.entries = null;
 47  25
         }
 48  
         
 49  14
         public StringMapEntryList(List<StringMapEntry> entries) {
 50  14
                 this.entries = new ArrayList<StringMapEntry>(entries);
 51  14
         }
 52  
         
 53  
         /**
 54  
          * @return the attribute
 55  
          */
 56  
         public List<StringMapEntry> getEntries() {
 57  50
                 if (this.entries == null) {
 58  0
                         return Collections.emptyList();
 59  
                 }
 60  50
                 return Collections.unmodifiableList(entries);
 61  
         }
 62  
 }