Coverage Report - org.kuali.student.lum.course.dto.FormatInfo
 
Classes in this File Line Coverage Branch Coverage Complexity
FormatInfo
0%
0/29
0%
0/4
1.125
 
 1  
 /*
 2  
  * Copyright 2009 The Kuali Foundation
 3  
  *
 4  
  * Licensed under the Educational Community License, Version 1.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/ecl1.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.student.lum.course.dto;
 17  
 
 18  
 import java.io.Serializable;
 19  
 import java.util.ArrayList;
 20  
 import java.util.HashMap;
 21  
 import java.util.List;
 22  
 import java.util.Map;
 23  
 
 24  
 import javax.xml.bind.annotation.XmlAccessType;
 25  
 import javax.xml.bind.annotation.XmlAccessorType;
 26  
 import javax.xml.bind.annotation.XmlAttribute;
 27  
 import javax.xml.bind.annotation.XmlElement;
 28  
 import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter;
 29  
 
 30  
 import org.kuali.student.common.dto.HasAttributes;
 31  
 import org.kuali.student.common.dto.HasTypeState;
 32  
 import org.kuali.student.common.dto.Idable;
 33  
 import org.kuali.student.common.dto.MetaInfo;
 34  
 import org.kuali.student.common.dto.TimeAmountInfo;
 35  
 import org.kuali.student.core.ws.binding.JaxbAttributeMapListAdapter;
 36  
 
 37  
 /**
 38  
  * Detailed information about a single course.
 39  
  *
 40  
  * @Author KSContractMojo
 41  
  * @Author Kamal
 42  
  * @Since Tue May 18 11:30:55 PDT 2010
 43  
  * @See <a href="https://test.kuali.org/confluence/display/KULSTU/formatInfo+Structure">FormatInfo</>
 44  
  *
 45  
  */
 46  
 @XmlAccessorType(XmlAccessType.FIELD)
 47  0
 public class FormatInfo implements Serializable, Idable, HasTypeState, HasAttributes {
 48  
 
 49  
     private static final long serialVersionUID = 1L;
 50  
 
 51  
     @XmlElement
 52  
     private List<ActivityInfo> activities;
 53  
 
 54  
     @XmlElement
 55  
     private List<String> termsOffered;
 56  
 
 57  
     @XmlElement
 58  
     private TimeAmountInfo duration;
 59  
     
 60  
     @XmlElement
 61  
     @XmlJavaTypeAdapter(JaxbAttributeMapListAdapter.class)
 62  
     private Map<String, String> attributes;
 63  
 
 64  
     @XmlElement
 65  
     private MetaInfo metaInfo;
 66  
 
 67  
     @XmlAttribute
 68  
     private String type;
 69  
 
 70  
     @XmlAttribute
 71  
     private String state;
 72  
 
 73  
     @XmlAttribute
 74  
     private String id;
 75  
 
 76  
     
 77  
     /**
 78  
      * 
 79  
      */
 80  
     public List<ActivityInfo> getActivities() {
 81  0
         if (activities == null) {
 82  0
             activities = new ArrayList<ActivityInfo>(0);
 83  
         }
 84  0
         return activities;
 85  
     }
 86  
 
 87  
     public void setActivities(List<ActivityInfo> activities) {
 88  0
         this.activities = activities;
 89  0
     }
 90  
     
 91  
     public List<String> getTermsOffered() {
 92  0
         return termsOffered;
 93  
     }
 94  
 
 95  
     public void setTermsOffered(List<String> termsOffered) {
 96  0
         this.termsOffered = termsOffered;
 97  0
     }
 98  
 
 99  
     public TimeAmountInfo getDuration() {
 100  0
         return duration;
 101  
     }
 102  
 
 103  
     public void setDuration(TimeAmountInfo duration) {
 104  0
         this.duration = duration;
 105  0
     }
 106  
 
 107  
     /**
 108  
      * List of key/value pairs, typically used for dynamic attributes.
 109  
      */
 110  
     public Map<String, String> getAttributes() {
 111  0
         if (attributes == null) {
 112  0
             attributes = new HashMap<String, String>();
 113  
         }
 114  0
         return attributes;
 115  
     }
 116  
 
 117  
     public void setAttributes(Map<String, String> attributes) {
 118  0
         this.attributes = attributes;
 119  0
     }
 120  
 
 121  
     /**
 122  
      * Create and last update info for the structure. This is optional and treated as read only since the data is set by the internals of the service during maintenance operations.
 123  
      */
 124  
     public MetaInfo getMetaInfo() {
 125  0
         return metaInfo;
 126  
     }
 127  
 
 128  
     public void setMetaInfo(MetaInfo metaInfo) {
 129  0
         this.metaInfo = metaInfo;
 130  0
     }
 131  
 
 132  
     /**
 133  
      * Unique identifier for a learning unit type. Once set at create time, this field may not be updated.
 134  
      */
 135  
     public String getType() {
 136  0
         return type;
 137  
     }
 138  
 
 139  
     public void setType(String type) {
 140  0
         this.type = type;
 141  0
     }
 142  
 
 143  
     /**
 144  
      * The current status of the course. The values for this field are constrained to those in the luState enumeration. A separate setup operation does not exist for retrieval of the meta data around this value. This field may not be updated through updating this structure and must instead be updated through a dedicated operation.
 145  
      */
 146  
     public String getState() {
 147  0
         return state;
 148  
     }
 149  
 
 150  
     public void setState(String state) {
 151  0
         this.state = state;
 152  0
     }
 153  
 
 154  
     /**
 155  
      * Unique identifier for a Canonical Learning Unit (CLU). This is optional, due to the identifier being set at the time of creation. Once the Format has been created, this should be seen as required.
 156  
      */
 157  
     public String getId() {
 158  0
         return id;
 159  
     }
 160  
 
 161  
     public void setId(String id) {
 162  0
         this.id = id;
 163  0
     }
 164  
 }