1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17 package org.kuali.student.enrollment.courseoffering.dto;
18
19 import java.util.ArrayList;
20 import java.util.List;
21
22 import javax.xml.bind.annotation.XmlAccessType;
23 import javax.xml.bind.annotation.XmlAccessorType;
24 import javax.xml.bind.annotation.XmlAnyElement;
25 import javax.xml.bind.annotation.XmlElement;
26 import javax.xml.bind.annotation.XmlType;
27
28 import org.kuali.student.enrollment.courseoffering.infc.ActivityOfferingCluster;
29 import org.kuali.student.enrollment.courseoffering.infc.ActivityOfferingSet;
30 import org.kuali.student.r2.common.dto.IdEntityInfo;
31
32 import org.w3c.dom.Element;
33
34
35
36
37 @XmlAccessorType(XmlAccessType.FIELD)
38 @XmlType(name = "ActivityOfferingClusterInfo", propOrder = {
39 "id", "typeKey", "stateKey", "name", "descr",
40 "privateName", "formatOfferingId", "activityOfferingSets",
41 "meta", "attributes", "_futureElements"})
42
43 public class ActivityOfferingClusterInfo
44 extends IdEntityInfo
45 implements ActivityOfferingCluster {
46
47 private static final long serialVersionUID = 1L;
48
49 @XmlElement
50 private String privateName;
51
52 @XmlElement
53 private String formatOfferingId;
54
55 @XmlElement
56 private List<ActivityOfferingSetInfo> activityOfferingSets;
57
58 @XmlAnyElement
59 private List<Element> _futureElements;
60
61
62
63
64
65 public ActivityOfferingClusterInfo() {
66 }
67
68
69
70
71
72
73
74 public ActivityOfferingClusterInfo(ActivityOfferingCluster template) {
75 super(template);
76
77 if (template == null) {
78 return;
79 }
80
81 this.formatOfferingId = template.getFormatOfferingId();
82 if (template.getActivityOfferingSets() != null) {
83 this.activityOfferingSets = new ArrayList<ActivityOfferingSetInfo>(template.getActivityOfferingSets().size());
84 for (ActivityOfferingSet aotemplate : template.getActivityOfferingSets()) {
85 this.activityOfferingSets.add(new ActivityOfferingSetInfo(aotemplate));
86 }
87 }
88 }
89
90 @Override
91 public String getPrivateName() {
92 return this.privateName;
93 }
94
95 public void setPrivateName(String privateName) {
96 this.privateName = privateName;
97 }
98
99 @Override
100 public String getFormatOfferingId() {
101 return formatOfferingId;
102 }
103
104 public void setFormatOfferingId(String formatOfferingId) {
105 this.formatOfferingId = formatOfferingId;
106 }
107
108 @Override
109 public List<ActivityOfferingSetInfo> getActivityOfferingSets() {
110 if (activityOfferingSets == null) {
111 activityOfferingSets = new ArrayList<ActivityOfferingSetInfo>();
112 }
113
114 return activityOfferingSets;
115 }
116
117 public void setActivityOfferingSets(List<ActivityOfferingSetInfo> activityOfferingSets) {
118 this.activityOfferingSets = activityOfferingSets;
119 }
120 }